Since the dawn of history, man did not find any means better than fast to ascend above yielding to his desires and worldly wishes, attain spiritual upliftment, return to spirituality, and renounce contemptible habits to which he became addicted and which led him to perdition. Divinely revealed creeds, non-Muslim societies and former nations have been familiar with the fast. Ancient Egyptians, Greeks, Romans, Chinese and other nations knew and practiced fast for various reasons. Many still do even today. The Greeks came to know about fast and its merits from ancient Egyptians. They used to fast immediately before engaging in a war.
The Romans emulated the Greeks not only in mythology, but also in observing the fast, especially when they were attacked, in order to gain victory. They believed that fast strengthened them and taught them patience and perseverance, two prerequisites required to win the battle against internal temptations and external dangers. Ancient Chinese, too, incorporated fast into their doctrines and prescribed it for those who were passing through periods of trials and tribulations.
For centuries, Hindus and Buddhists have been observing a somehow more rigid form of fast. Jews and Christians observe certain types of fast. Moses, peace be upon him, observed the fast for forty days at Mount Sinai; see Exodus 24:18. During that period, he was granted the heavy responsibilities embedded in the Ten Commandments.
He was commanded in the Torah to fast the tenth day of the seventh month and the ninth of the eighth. Jews used to (and some still do) fast during times of grief and mourning and when exposed to danger. They were also accustomed to fast one day as an act of atonement and whenever they believed that God was angry with them.
Nowadays, they fast one week to commemorate the destruction of Jerusalem at the hands of Nebuchadnezzar II (605-562 B.C.) son of Nabopolassar, founder of the Chaldean or Neo-Babylonian empire, on March 16, 597 B.C. They observe fast on other days, too.
Jesus of Nazareth (6 B.C.-30 A.D.), peace be upon him and his virgin mother Mary daughter of Imran (Amram), was reported to have observed the fast on the day of atonement. He and his disciples fasted the forty days observed by Moses before him; see Matthew 4:2. This set the precedence for the pre-Easter fast among some Christians. Other Christian theologians started other types of fast during which they do not eat meat, fish, or eggs.