Walking, it normally took about two weeks to make the trip from Egypt to what is now Israel. It took Moses and the Israelites 40 years. They bypassed the coastal route to avoid Egyptian outposts. Then God sentenced them to 40 years in the Badlands for refusing to go into the Promised Land after scouts warned them about giants and walled cities ahead (Deuteronomy 1). Strange and Mysterious Stuff in the Bible, p. 18.