Oracle
1Z0-803 · Question #266
1Z0-803 Question #266: Real Exam Question with Answer & Explanation
Sign in or unlock 1Z0-803 to reveal the answer and full explanation for question #266. The question stem and answer options stay visible for context.
Question
Given: abstract class A1 { public abstract void m1(); public void m2() { System.out.println("Green"); } } abstract class A2 extends A1 { public abstract void m3(); public void m1() { System.out.println("Cyan"); } public void m2() { System.out.println("Blue"); } } public class A3 extends A2 { public void m1() { System.out.println("Yellow"); } public void m2() { System.out.println("Pink"); } public void m3() { System.out.println("Red"); } public static void main(String[] args) { A2 tp = new A3(); tp.m1(); tp.m2(); tp.m3(); } } What is the result?
Options
- AYellow
- BCyan
- CCyan
- DCompilation Fails
Unlock 1Z0-803 to see the answer
You've previewed enough free 1Z0-803 questions. Unlock 1Z0-803 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.