Ever since the fall of Adam and Eve, God has been trying to get people to change their wicked ways and not give in to sin.
He warned Cain that his anger toward his brother, Abel, was sinful and not to give in to it. But Cain did not listen and instead committed the first murder by killing his brother.
In Genesis 6, we read that God saw "how great the wickedness of human beings was on earth."
God was very sorry that he had made human beings. So he decided to send a great flood to destroy everyone on earth except a righteous man named Noah, along with Noah's family and two of every creature on earth.
After God destroyed all the wicked people on earth and the floodwaters receded, he said, "Never again will I curse the ground because of human beings, since the desires of the human heart are evil from youth."
Even though God knows people tend to sin, he still loves us and wants to give us the chance to be forgiven and change our ways. He even sent us his son, Jesus, to die for our sins.
As we read in John 3:16, "For God so loved the world that he gave his only Son, so that everyone who believes in him might not perish but might have eternal life."