ADVANCED TOPICS IN COMPILER DESIGN
CODE GENERATION FOR OBJECT ORIENTED LANGUAGES
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
Which of the following is a superclass of every class in java?
|
ArrayList
|
|
Abstract class
|
|
Object class
|
|
String
|
Explanation:
Detailed explanation-1: -The class named Object is the super class of every class in Java.
Detailed explanation-2: -Object class in java is the super most class in java. Every class incjava directly or indirectly inherit the Object class. The Object class is the parent class of all the classes in java by default. In other words, it is the topmost class of java.
Detailed explanation-3: -A Java class is not an object. However, every Java class has an instance of the Class class describing it. Those instances are objects.
There is 1 question to complete.