Question: What is the output of the Light program? A. 5,5,5 B. 5,5,7 C. 5,7,7 D. 7,7,7 E. The code does not compile. F. None of

What is the output of the Light program? 

package physics; class Wave { public int size = 7; } public

A. 5,5,5

B. 5,5,7

C. 5,7,7

D. 7,7,7

E. The code does not compile.

F. None of the above.

package physics; class Wave { public int size = 7; } public class Light extends Wave { public int size = 5; public static void main(String... emc2) { } } Light v1 = new Light(); var v2 = new Light (); Wave v3 = new Light(); System.out.println (v1.size +","+ v2.size +","+ v3.size);

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

Answer The correct answer is B 5 5 7 Explanation The Light cl... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Oracle Questions!