A:
It is obligatory
for a Muslim to learn the religious principles that enable them to practice their religion. It is not permissible to let anything preoccupy them from this obligation. Studying medicine is a collective obligation, whereas studying the fundamentals that a Muslim needs to know about the religion of Islam is an individual obligation, and individual obligations are given priority over collective obligations. Therefore, it is obligatory for you as a Muslim to learn the necessary Islamic knowledge and this will not impede your ability to study medicine. You can turn your study of medicine into worship through learning it for the Sake of Allah (Exalted be He) and for the benefit of yourself and Muslims. (Part No. 12; Page No. 90) In addition, if you have the intention to study medicine so that you can look after people's health and protect them from diseases by the Will of Allah (Glorified and Exalted be He), your study of medicine will turn into worship.May Allah grant us success. May peace and blessings be upon our Prophet Muhammad, his family, and Companions.