As with all living things, Allah created human beings for a purpose and explains that purpose in the Qur'an, which He sent down to guide all people: "Did you suppose that We created you for amusement and that you would not return to Us?" (Surah Ghafir, 115) and "I only created jinn and man to worship Me" (Surat adh-Dhariyat, 56). In other words, all people were created to serve Allah.
Human beings have a lifespan of roughly 60 to 70 years. But like an hourglass, time is constantly running out. Everyone will stay in this world for a length of time that is known only to Allah, for it follows the destiny that Allah has determined for it and which no person or thing can change.
Everything in this world will end when its time comes, for "the life of this world, compared to the Hereafter, is only fleeting enjoyment" (Surat ar-Ra`d, 26). Everything here grows old and diminishes as it rushes headlong toward destruction. Time destroys everyone and everything, and those who attach themselves to this transitory life stand to lose everything. That is why our Prophet (saas) recommended to people to think about death and said: "Those who are most aware of death and prepare themselves for it. They are the wisest of people."
In his works, the great Islamic scholar Bediuzzaman Said Nursi constantly reminded his readers that this earthly life is transitory and that everyone must work hard to attain the life of the Hereafter:
The world is a guest-house, and as for man, he remains there only a short time. He is a guest with many duties and in a brief lifetime is charged with preparing all the necessities for eternal life. 2
Bediuzzaman describes the shortness of human life as a temporary visit and, in another example, says that "human beings, like animals, have been given existence to perpetuate their life in the world." He then adds:
O my soul and my friend! Come to your senses! Do not spend the capital and potentialities of your life on pleasures of the flesh and this fleeting life like an animal, or even lower. Otherwise, although you are fifty times superior with regard to capital than the highest animal, you will fall fifty times lower than the lowest.3
As he says, human beings are endowed with such superior qualities as intelligence, conscience, and common sense. Thus, the purpose of their creation is clearly not to chase after the temporary pleasures of this short and highly deficient worldy life, but to attain the beauty of eternity by using their superior qualities to pass the tests in this world.
People are tested according to how they respond to what they encounter in the world, as well as how they exercise their moral characters and intentions. It is definitely not enough for them to say "I believe"; rather, they must show their faith through their actions and words. On the Day of Judgment, everything they have done, both public and private, will be revealed and they will have to give a detailed account. While doing so, they will not suffer any injustice, for the Qur'an says "They will not be wronged by so much as the smallest speck." (Surat an-Nisa', 49). Those whose good deeds weigh heavy in the balance will be received into the eternal beauties of Paradise, while those who chose the way of evil and oppression will find their reward in the eternal torment of Hell. Allah created this short life as a testing place, for:
He Who created death and life to test which of you is best in action. He is the Almighty, the Ever-Forgiving. (Surat al-Mulk, 2)
This entry is from one chap from 'The Secret behind Our Trials' by Harun Yahya..He is one of da writer who loves to write based on al-Quran.