Java Programming
Question 1: What is the output of this program? class A { int i; int j; A(){ i = 1; j = 2; } } class Output { public static void main(String args[]){ A obj1 = new A(); A obj2 = new A(); System.out.print(obj1.equals(obj2)); } }
false true 1 Compilation Error
Object class Object class java.lang.Object Compilation Error
true false String associated with obj1 Compilation Error
Encapsulation Interface Composition Inheritance
String class Object class Abstract class None of the above.
Polymorphism Abstraction Encapsulation Recursion
public static void main (String [ ] args) public static strictfp void main(String args[ ]) final static public void main (String args[ ] All are Correct
Number of score out of 7 = Score in percentage =