Menu

Why Java doesn't support multiple inheritance?

Java doesn't support multiple inheritance because of deadlock and ambiguity situation.

A class cannot extend two classes, but a class can implement multiple interfaces. So, we use interfaces to achieve multiple inheritance in Java programming.

e.g. Class C extends A, B { //statements }

The above class declaration is invalid in Java programming. but possible in various other programming languages.

e.g. Class C extends A implements D, F { //codes }

The above class declaration is valid in Java. In the above class declaration, we have inherited class A and implementing two interfaces D and F. This way we can implement multiple interfaces in Java.

Example Class C extends Class A and Class B and both classes A and B have evaluate() method. When class C tries to inherit evaluate method then the compiler will get confused and unable to decide which evaluate method to inherit, either from class A or B. So to remove this ambiguity from the program Java doesn't support multiple inheritance.

Why we use Radhiallah Anhu or Anha with the name of companions of Prophet Muhammad SAW?

Radhiallah Anhu or Radhiallah Anha means May Allah be pleased with him/her. It is added after the names of the sahabah (companions of Prophet Muhammad ﷺ) and wives of Prophet Muhammadﷺ as a sign of respect. It is often represented by the acronyms(RA or R). 

Raziallahu Anhu is used for male companions and Raziallahu Anha is used for female companions of Prophet Muhammadﷺ.

Arabic text - 
Radhiallah Anhum رضي الله عنهم (for plural male) and
Rathiallah Anhu رضي الله عنه (for singular male)
Rathiallah Anha رضي الله عنها (for singular female)

Islamic Republics

The Islamic republic is a state that is officially ruled by the law of Islam(Islamic Laws). Till the year 2020 world has four countries that are named Islamic republic. Those states are following.
1. Islamic Republic of Afghanistan
2. Islamic Republic of Iran
3. Islamic Republic of Mauritania and
4. Islamic Republic of Pakistan

Pakistan is the first state that adopted the title Islamic Republic under the constitution of 1956; Mauritania adopted it on 28 November 1958; Iran adopted it after the 1979 Iranian Revolution that overthrew the Pahlavi dynasty; and Afghanistan adopted the title of Islamic republic after the fall of the Taliban government leads by Mulla Omar in the year 2004.

What are Islamic Laws?

Islamic laws are the constitution to manage the law and order, society, polity, rights, and family based on the natural laws and laws given by God and prophets.