Can an interface extands a class?

Answer Posted / pramod p deore

No, an interface can extends only other interface.
Interface can not extends a class or abstract class.

1) a class can implements an interface but does not extends
interface.
2) interface can extends other interface but does not
implemets other interface.
3) a class can extends other class but does not implements
other class.

Is This Answer Correct ?    60 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the features of java?

525


Can an interface implement another interface?

564


Difference between operator overloading and function overloading

601


What is static variable with example?

551


What happens if a constructor is declared private?

522






What is length in java?

562


Why are the methods of the math class static?

570


I want to re-reach and use an object once it has been garbage collected. How it's possible?

531


Why singleton is not thread safe?

559


Is it possible to cast an int value into a byte variable? What would happen if the value of int is larger than byte?

539


What is the largest data type in java?

504


A person says that he compiled a java class successfully without even having a main method in it? Is it possible?

577


What are multiple inheritances? Is it supported by java?

453


What are JVM.JRE, J2EE, JNI?

680


Can we overload destructor in java?

534