Java OCA OCP Practice Question 1412

Question

Fill in the blanks:

Because of ___, we can ___ a method, which allows Java to support ___.

  • A. abstract methods, override, inheritance
  • B. concrete methods, overload, inheritance
  • C. virtual methods, overload, interfaces
  • D. inheritance, abstract, polymorphism
  • E. virtual methods, override, polymorphism.


E.

Note

The only answer that is valid is Option E.

Without virtual methods, overriding a method would not be possible, and Java would not truly support polymorphism.




PreviousNext

Related