There's really nothing wrong with praying but it cannot be the one solution that is to be given more so to a depressed person. Even before the so called organized religions you see now, your ancestors used to pray and so did the moral philosophers...its part of trying to comprehend...