Welcome Guest | Sign in | Register
Inner Classes - Discussion Page For Q.3040 | Java Programming Questions and Answers | Java Programming Free Online-Tests | LucentBlackBoard | LucentBlackBoard.com

Home > Java Programming > Inner Classes > Questions and Answers

Q: Which are true about an anonymous inner class?
A. can extend exactly one class and implement exactly one interface B. can extend exactly one class or implement exactly one interface.
C. can implement multiple interfaces if it does not extend a class. D. can implement multiple interfaces if it does not extend a class.

Answer and Explanation

Answer:can extend exactly one class or implement exactly one interface.

Explanation:
syntax of an anonymous inner class allows for only one. can extend exactly one class or implement exactly one interface. Ianimal c = new Ianimal() { } Ianimal can be
class or interface.

Comment on this Question

Name:

Loading...




Partner Sites
LucentBlackBoard.com                  SoftLucent.com                  LucentJobs.com
All rights reserved © 2012-2015 SoftLucent.