Programming  Java  Class and Object

1. Which of the following is an invalid declaration for the main method in java program?

public static void main (String [ ] args) public static strictfp void main(String args[ ]) final static public void main (String args[ ]) All are Correct
Comments

Share QNo: 1

2. A top level class may have which one of the following access modifiers?

package private protected public
Comments

Share QNo: 2

3. Visualizing program components as objects is characteristics of which of the following language types?

Object-oriented programming language Machine language Command line operating system Procedural language
Comments

Share QNo: 3

4. A subclass is also called as

inner class nested class derived class hidden class
Comments

Share QNo: 4

5. Attribute of an object can include information about

State Method Behavior Procedures
Comments

Share QNo: 5

6. Which of the following is not a wrapper class?

Vector Character Boolean Integer
Comments

Share QNo: 6

7. Which of the following method is used to initialize the instance variable of a class?

Class Public Constructor Destructor
Comments

Share QNo: 7

8. Object oriented programming method is followed in

C programming language C++ programming language C# programming language Both b and c
Comments

Share QNo: 8

9. The last statement in a finalize method should always be

super (finalize) super finalize() finalize(method name) no restrictions
Comments

Share QNo: 9

10. The methods defined by Thread class that help to manage threads are :

joined stop getName all of the above
Comments

Share QNo: 10

 

*Click on the QNo to display a Question.

Total Ans