Basic and Advance Java Question: Download Java PDF

Can an anonymous class be declared as implementing an interface and extending a class in Java Programming?

Tweet Share WhatsApp

Answer:

An anonymous class may implement an interface or extend a superclass, but may not be declared to do both.

Download Java PDF Read All 81 Java Questions
Previous QuestionNext Question
How can you write a loop indefinitely in Java Programming?What is the purpose of finalization in Java Programming?