Java | Class and Object | Question 7
Predict the output of the following program.
obj1.a = 1 obj1.b = 2 obj2.a = 4 obj2.b = 3
obj1.a = 4 obj1.b = 3 obj2.a = 4 obj2.b = 3
(C) Compilation error
obj1 and obj2 refer to same memory address.
Quiz of this Question
Please comment below if you find anything wrong in the above post
My Personal Notes arrow_drop_up