Answer Posted / suresh
No a interface should not have constructor,
Because, interface will not extends with object class.
if any class extends with object class then atleast one
constructor should be there, if user fail to keep the
constructor the compiler will keep a default constructor
with first statement as super();.
| Is This Answer Correct ? | 6 Yes | 2 No |
Post New Answer View All Answers
Explain the private field modifier?
How can you set the applet size?
How are multiple inheritances done in Java?
What is application tier?
How do you trim a space in java?
What is the use of math abs in java?
What are the types of collections in java?
What do you mean by Function Overloading in java?
How does multithreading take place on a computer with a single cpu in java programming?
How transient variable is different from volatile variable?
What is thread count in java?
Is string is a data type?
What do you understand by classes in java?
Which browsers work with java?
why Interface used?