Million Dollar Question Flashcards
(20 cards)
Can a interface implement class?
False
Can a abstract class have a abstract method?
True
Can a interface have a abstract method?
True
What kind of field can a abstract class have?
Any kind, as long as it is a class (static, instance, finanl, non-final)
What kind of field can a interface class have?
only constant which is public, static and final
Can a abstract class have a constructor?
True
Can interface class have a constructor?
False
Can a abstract class have a instance block?
yes, you can have anything
Can abstract classes have a concrete method?
True
Can interface have a method that has a body?
default and static method must have body
Can a abstract class implement multiple interface?
True
Can a abstract class extend multiple another class?
False
Can a interface implement a class?
False
Can a interface extend another interface?
True
Can a class implement other class?
False
Can interface extend multiple another interface
True
Can a interface can have any other access modifier ?
only public, if it is protected it will not compile
Member of interface can be static?
False, it cannot.
Does Interface contains Data Member?
False
Does abstract contains Data Member?
True