Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

Consider the following abstract interface and abstract class. abstract interface

ID: 3820600 • Letter: C

Question

Consider the following abstract interface and abstract class. abstract interface CircusShow {abstract public void entrance (); abstract public void act (); abstract public void announcement (); abstract public void performance (); abstract public void exit ();} abstract class circusShow {abstract public void entrance (); abstract public void act (); abstract public void announcement (); abstract public void performance (); abstract public void exit ();} What is the difference between the use of abstract interface and the abstract class? (A) They are used exactly in the same manner in a program. There is no difference. (B) The interface allows polymorphism, while the class cannot be used for polymorphism. (C) The class allows polymorphism, while the interface cannot be used for polymorphism. (D) One uses the reserved word interface and the other uses the reserved word class. (E) Using the interface requires implements and using the class requires extends.

Explanation / Answer

The correct answer is (c), As interface allows us to define polymorphism in a declerative way, rather than implementation.

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote