Praise be to Allah.
Ramadan fast is the fourth pillar of Islam
The Ramadan fast is one of the pillars on which Islam is based. Al-Bukhari (8) and Muslim (16) narrated that Ibn `Umar (may Allah be pleased with him) said: The Messenger of Allah (peace and blessings of Allah be upon him) said: “Islam is built on five (pillars): the testimony that there is no god except Allah and that Muhammad is the Messenger of Allah; establishing regular prayer; paying zakah; fasting Ramadan, and performing Pilgrimage to the House (the Ka`bah).”
Whoever does not fast has abandoned one of the pillars of Islam and has committed a grave major sin. In fact, some of the salaf were of the view that such a one is a disbeliever and an apostate – Allah forbid.
Al-Dhahabi (may Allah have mercy on him) said in al-Kabair (p. 64):
The believers unanimously agreed that whoever forsakes the Ramadan fast when he is not sick and has no other excuse for that is worse than an adulterer or one who is addicted to alcohol. They doubt whether he is a Muslim and they think of him as a heretic and deviant. End quote.
Can you skip fasting during exams?
As for breaking the fast because of exams, Shaykh Ibn Baz (may Allah have mercy on him) was asked about that and he replied:
“It is not permissible for an adult of sound mind to break the fast during Ramadan because of exams, because that is not one of the excuses permitted in Islam. Rather he has to fast and do his studying at night if it is hard for him to do it during the day. Those who are in charge of exams should be kind to the students and arrange the exams at a time other than Ramadan, so as to serve two purposes: the purpose of fasting and that of giving students time to prepare for the exams. It is narrated in a sahih report that the Messenger of Allah (peace and blessings of Allah be upon him) said: "O Allah, whoever is appointed over any of my ummah’s affairs and treats them kindly, treat him kindly, and whoever is appointed over any of my ummah’s affairs and treats them harshly, treat him harshly." (Narrated by Muslim in his sahih)
So my advice to those who are in charge of exams is to be kind to the students and not organize the exams in Ramadan, rather to do them before or after that. We ask Allah to guide us all.” (Fatawa al-Shaykh Ibn Baz, 4/223)
The Standing Committee was asked: I am going to be tested in Ramadan for a period of 6 and a half consecutive hours, with a 45 minute break. I did the same test last year, but I could not concentrate because of fasting. Is it permissible for me to break the fast on the day of the test?
“It is not permissible to break the fast for the reason you mentioned, rather that is haram, because it is not included among the excuses for which it is permissible to break the Ramadan fast.” (Fatawa al-Lajnah al-Daimah, 10/240)
Making up missed fasts due to exams
With regard to whether it is obligatory to make up the fasts , it depends.
If you broke the fast because you thought that it was permissible to do so because of the exams, then you have to make it up, because you are excused for this mistaken thinking, and you did not deliberately commit a haram action.
But if you broke your fast and you knew that it was haram to do so, then you have to repent and regret this sin, and resolve not to commit this grave sin again.
As for making it up, if you broke the fast during the day after having started to fast, then you have to make it up, but if you did not fast at all, then you do not have to make it up, and it is sufficient to repent to Allah sincerely. And you have to do a lot of righteous deeds such as observing voluntary fasts etc., that will make up for the shortfall in fulfilling the obligatory duty.
Breaking the fast for no legitimate reason
Shaykh Ibn 'Uthaymin (may Allah have mercy on him) was asked about the ruling on breaking the fast during the day in Ramadan for no legitimate reason .
“Breaking the fast during the day in Ramadan for no legitimate reason is one of the worst of major sins, because of which a person may be regarded as a fasiq (disobedient, rebellious) who has to repent to Allah and make up for the day when he broke the fast. I.e., if he fasted, then during the day he broke his fast with no excuse, he has committed a sin, and he has to make up that day because when he started that fast, it became binding on him to complete it, so he has to make it up, like a vow. But if he did not fast at all, deliberately and with no excuse, then the correct view is that he does not have to make it up, because that will not benefit him at all, as it will never be accepted from him. The basic principle with regard to acts of worship that are connected to specific times is that if a person delays them beyond that specific time with no excuse, they will not be accepted from him, because the Prophet (peace and blessings be upon him) said: "Whoever does a deed that is not in accordance with this matter of ours, will have it rejected." And because it is a transgression of the sacred limits of Allah, may He be glorified and exalted, and transgressing the sacred limits of Allah is zulm (wrongdoing), and no deeds are accepted from the zalim (wrongdoer). Allah says (interpretation of the meaning):
“And whoever transgresses the limits ordained by Allah, then such are the Zalimun (wrongdoers).” [al-Baqarah 2:229]
If he does this act of worship early – i.e., before the time for it begins – it will not be accepted from him, and similarly if he does it after that, it will not be accepted from him, unless he has an excuse.” (Majmu' Fatawa al-Shaykh Ibn 'Uthaymin, 19; question no. 45)
Delaying making up missed fasts for years
You have to repent to Allah for delaying making up the fasts all these years. The one who owes days from Ramadan has to make them up before the next Ramadan begins. If he delays that, he is committing a haram action, but does he have to offer the expiation of feeding one poor person for each day because of this delay? There is a dispute among the scholars concerning that, but the most correct view is that he does not have to do so, but if he does that in order to be on the safe side, that is good.
To sum up, you have to make up the fasts if you thought that it was permissible to break the fast because of the exams, or if you broke the fast during the day, but you do not have to offer expiation as well as make up the fasts.
We ask Allah to accept your repentance.
And Allah knows best.