Return to site

JAVA CERTIFICATION QUESTION: Working with abstract classes and default methods in Java

=>What happens when a default method is hidden and inaccessible?

· java,ocp

Given the following classes and an interface:

What is the result? Choose one.

A. The Bird class fails to compile.

B. The Chicken class fails to compile.

C. Default fly is printed.

D. Cannot fly is printed.

 

·ꓷ sᴉ ɹǝʍsuɐ ʇɔǝɹɹoɔ ǝɥꓕ