I think it is good to question what our purpose in life here on earth is. From The Church of Jesus Christ of Latter-day Saint perspective, God could never create us to be perfect beings and thus uses a means of teaching us how to become perfect. In our faith we believe that the intelligence of mankind was never create or made and neither indeed can be. In other words, our intelligence is self-existing. Since God could not create our intelligence, He could not create it to be perfect. However, we do have the capacity to improve our lot in life. God is as perfect a being as one can become. For us to improve our lot and become more like God, we need to learn to become good beings in and of ourselves. Thus the need for free will. One can only become a truly good being by choosing to be good of his own free will and choice. Otherwise we would be nothing but puppets. Free will is critical. To love and be loved is one of the great aspects of existence which brings us joy and happiness. God is a being who loves. He took our eternal intelligences and through the process of procreation he caused that our intelligences were to be combined with spiritual matter to form the spirits that are within our bodies. In other words, our spirits are the literal offspring of God.
Acts 17:28-29
28 For in him we live, and move, and have our being; as certain also of your own poets have said, For we are also his offspring.
29 Forasmuch then as we are the offspring of God, we ought not to think that the Godhead is like unto gold, or silver, or stone, graven by art and man’s device.
As the children of God, God loves us and wants us to progress to become like him.
Matthew 5:48
48 Be ye therefore perfect, even as your Father which is in heaven is perfect.
For us to become perfect like our Father in heaven, we must learn to choose good over evil and learn to love one another. This mortal life is a chance for us to improve our character and become more like our Father in Heaven. We are give free will to choose good over evil and we are also give the chance to experience good and evil by living through a mortal world. This life is a school ground for us to experience good and evil and learn to choose the good over the evil. Thanks to God, he has provided a mean whereby if we make mistakes we can change from doing evil to doing good and receive forgiveness for our past faults. God also provided a mean whereby we will all be resurrected to an immortal state with bodies of flesh and bones. Thus we will be able to look back on this mortal life as a temporary school ground to see if we would choose good over evil. Again, to truly become a good being in and of ourselves, we must learn to choose, of our own free will and choice, to be good beings. Free will is critical. The consequence of free will is that some will choose evil over good and not reach their full potential. God is merely giving us the chance to become the best we are willing to become. In the end we will all live again immortally and not be subject to the ills of this temporary existence we experience now. We often look at this life as difficult and painful. Most all of us will suffer death and many other hardships in this life. This is all to give us knowledge and experience for our eternal progression and will come to end. We will eventually live forever immortally and not have to suffer these things in the hereafter. We will all look back and maybe have some laughs as we remember our mortality.
Jesus is known as the way, the truth, and the life. All we need to do to be successful is follow him in his teachings and his example in life to be successful in ours.