Dear Berean,
Adam and Eve sinned because God planned and caused them to sin. It did not happen by chance.
God caused Adam and Eve to sin by creating them spiritually marred (Jer 18:4) and subject to vanity (Rom 8:20). In this weak spiritual condition, the body of flesh that He gave them quickly started governing their spirit, causing it to have a carnal nature. With a carnal spiritual nature, Adam and Eve's minds quickly became carnal as well.
In this condition, Adam and Eve would sin and sin often just as all their offspring do. Christ even placed Satan (who He made to be the "destroyer" of mankind, Isa 54:15) in the Garden of Eden to tempt Eve after her mind became carnal:
Gen 3:6 And when the woman saw that the tree was good for food (LUST OF THE FLESH), and that it was pleasant to the eyes (LUST OF THE EYES), and a tree to be desired to make one wise (PRIDE OF LIFE), she took of the fruit thereof, and did eat, and gave also unto her husband with her; and he did eat.
By tempting Eve to sin, Satan became mankind's destroyer just as God created him to be.
These scriptures also apply:
Ecc 1:13 An experience of evil God has given to the sons of humanity to humble them by it.
Ecc 7:13 Consider the work of God: for who can make that straight, which he hath made crooked?
Isa 45:7 I form the light, and create darkness: I make peace, and create evil: I the LORD do all these things.
Prov 16:4 The LORD hath made all things for himself: yea, even the wicked for the day of evil.
Isa 63:17 O LORD, why hast thou made us to err from thy ways, and hardened our heart from thy fear? Return for thy servants' sake, the tribes of thine inheritance.
In their spiritual carnal condition, Adam and Eve had no ability to choose following the law of God over the dictates of their flesh.
These verses apply:
Prov 16:1 The preparations of the heart in man, and the answer of the tongue, is from the LORD.
Prov 20:24 Man's goings are of the LORD; how can a man then understand his own way?
Jer 10:23 I know, Jehovah, that the way of man is not his own; it is not in a man that walketh to direct his steps.
Dan 4:35 And all the inhabitants of the earth are reputed as nothing; and he doeth according to his will in the army of the heavens, and among the inhabitants of the earth; and none can stay his hand, or say unto him, What doest thou?
The teaching that mankind has a free will ability to make choices is a lie from the destroyer via the spirit of anti-Christ. God is in complete control of everything that happens in this creation. Nothing happens by chance or by man's will - everything happens because God plans and causes it to happen.
So why does God do it this way?
Because this creation if for the purpose of creating many new children who will be like Him in spirit and in character. To accomplish this goal, God determined that it was necessary for mankind to have a knowledge of good and evil. For this reason, God made mankind in such a way so that mankind would sin. In the end, God will convert all mankind from the sinful creatures that we presently are (children of the devil), into a new creation that pleases Him (children of God).
Jer 18:4 And the vessel that he made of clay was marred in the hand of the potter: so he made it again another vessel, as seemed good to the potter to make it.
It was for the purpose of mankind's spiritual conversion that God sent Christ into the world:
1John 4:14 And we have seen and do testify that the Father sent the Son to be the Savior of the world.
When Christ finishes His work, this scripture below will be testified to be true:
1Tim 2:3 For this is good and acceptable in the sight of God our Savior; 4 who will have all men to be saved, and to come unto the knowledge of the truth. 5 For there is one God, and one mediator between God and men, the man Christ Jesus; 6 who gave himself a ransom for all, to be testified in due time.
As with physical child birth, the birth of God's children is also a painful experience for both the mother (Christ) and for the child (mankind).
Lastly, concerning the "foreknowledge" of God, there are ZERO scriptures that teach that God looks into the future to see how things turn out. This is not where His foreknowledge comes from. His foreknowledge is derived from His ability to CAUSE all things to turn out exactly as He has purposed and planned. God is not a fortuneteller.
Isa 46:10 Declaring the end from the beginning (foreknowledge), and from ancient times the things that are not yet done, saying, My counsel shall stand, and I will do all my pleasure: 11 Calling a ravenous bird from the east, the man that executeth my counsel from a far country: yea, I have spoken it, I will also bring it to pass; I have purposed it, I will also do it.
Isa 55:11 So shall my word be that goeth forth out of my mouth: it shall not return unto me void, but it shall accomplish that which I please, and it shall prosper in the thing whereto I sent it.
Joe