Programming - Inheritance

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

 
31.

Final variables should be declared in the beginning?                        


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




32.

Can we declare variable inside a method as final variables? Why?                        


A. Cannot because, local variable cannot be declared as final variables. B. Cannot because, global variable cannot be declared as final variables.
C. Cannot because, local variable cannot be declared as static variables. D. Cannot because, global variable cannot be declared as static variables.




33.

Can an abstract class may be final?                        


A. An abstract class may not be declared as final. B. An abstract class may be declared as final.
C. Can't Say D. None




34.

Does a class inherit the constructors of it's super class?                        


A. A class does not inherit constructors from any of it's super classes. B. A object does not inherit constructors from any of it's super classes.
C. A method does not inherit constructors from any of it's super classes. D. A variable does not inherit constructors from any of it's super classes.




35.

What restrictions are placed on method overloading?                        


A. Two methods may not have the same name and argument list but different return types. B. Two methods may not have the different name and argument list but different return types.
C. Two methods may not have the same name and argument list but same return types. D. Two methods may not have the different name and argument list but same return types.




36.

What restrictions are placed on method overriding?                        


A. Overridden methods must have the same name , argument list , and return type. The overriding method may not limit the access of the method it overridees.The overriding method may not throw any exceptions that may not be thrown by the overridden method. B. Overridden methods must have the different name , argument list , and return type. The overriding method may not limit the access of the method it overridees.The overriding method may not throw any exceptions that may not be thrown by the overridden method.
C. Overridden methods must have the same name , argument list , and return type. The overriding method may not limit the access of the method it overloads.The overriding method may not throw any exceptions that may not be thrown by the overridden method. D. Overridden methods must have the different name , argument list , and return type. The overriding method may not limit the access of the method it overloads.The overriding method may not throw any exceptions that may not be thrown by the overridden method.




« prev

1

2

3

4

5

6

7

next »

 
 



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