Alma 42:1 - 42:5
Alma 42: 1 And now, my son, I perceive there is somewhat more which doth worry your mind, which ye cannot understand—which is concerning the justice of God in the punishment of the sinner; for ye do try to suppose that it is injustice that the sinner should be consigned to a state of misery.
Now Alma discerns that there is another topic that is worry some to Corianton. Corianton thinks is very unfair that a sinner be assigned to a state of misery because they did not repent of their sins in life.
Alma 42: 2 Now behold, my son, I will explain this thing unto thee. For behold, after the Lord God sent our first parents forth from the garden of Eden, to till the ground, from whence they were taken—yea, he drew out the man, and he placed at the east end of the garden of Eden, cherubim, and a flaming sword which turned every way, to keep the tree of life—
Alma starts out by explaining that when Adam and Eve were removed from the Garden of Eden, they were forced to earn their living by becoming farmers. To prevent them from returning to the garden and eating of the Tree of Life and living forever as sinners, God placed an angel with a flaming sword to guard the tree.
Alma 42: 3 Now, we see that the man had become as God, knowing good and evil; and lest he should put forth his hand, and take also of the tree of life, and eat and live forever, the Lord God placed cherubim and the flaming sword, that he should not partake of the fruit—
The reason for this was that Adam and Eve had been given the ability to tell good from evil, something that is what Gods can do. Now if they could have eaten of the Tree of Life, they would have lived forever with this knowledge, but something was missing.
Alma 42: 4 And thus we see, that there was a time granted unto man to repent, yea, a probationary time, a time to repent and serve God.
They needed time understand the consequences their acts and quit those that were damning to them. This takes time and experience. So it was important that they had time to see what their evil acts did to one another and go through the process of trying to ridding themselves of the tendency to commit such acts.
Alma 42: 5 For behold, if Adam had put forth his hand immediately, and partaken of the tree of life, he would have lived forever, according to the word of God, having no space for repentance; yea, and also the word of God would have been void, and the great plan of salvation would have been frustrated.
However, if the couple had eaten of the Tree of Life immediately after eating of the Tree of the Knowledge of Good and Evil, they would have live forever in their fallen state, cut off from God and repentance would be of no consequence. They would be immortal and the plan of salvation could not have any effect on them.