Programming - Inheritance

You Are Here :: Home > JAVA > Inheritance - General Questions

 
13.

The first use of keyword __________________ is to access the hidden data variables of the super class hidden by the sub class.                        


A. this B. extends
C. super D. get




14.

What is the difference between superclass & subclass?                        


A. A super class is a class that is inherited whereas subclass is a class that does the inheriting. B. A parent class is a class that is inherited whereas subclass is a class that does the inheriting.
C. A child class is a class that is inherited whereas subclass is a class that does the inheriting. D. A parent class is a class that is inherited whereas super is a class that does the inheriting.




15.

Which keyword is used to inherit a class?                        


A. this B. extends
C. super D. get




16.

Subclasses methods can access superclass members/ attributes at all times?                        


A. FALSE B. TRUE
C. Can't Say D. None




17.

When can subclasses not access superclass members?                        


A. When superclass is declared as private. B. When superclass is declared as public.
C. When childclass is declared as private. D. When child class is declared as public.




18.

Which class does begin Java class hierarchy?                        


A. Object class B. Class
C. Variables D. Methods




« prev

1

2

3

4

5

6

7

next »

 
 



© 2013 freshersindia.in ® | Copyrights | Terms & Conditions
   Designed by Freshers India
Catch Us on