Answer Posted / paletipatisrinu
No we can instantiate interface directly.but we can create
instantiate of interface in directly
interface i1
{
public void wish();
}
public class A implements i1
{
public static void main(string...arg)
{
i1 o1=new A();
o1.wish();
}
public void wish()
{
System.out.println("we can create instantiate in directly");
}
}
Is This Answer Correct ? | 17 Yes | 1 No |
Post New Answer View All Answers
How many bits are in a sentence?
give an example for encapsulation?
What is constant in programming?
What is a constructor overloading in java?
Can we overload run() method in java?
Are registers volatile?
What is the method to expand and collapse nodes in a jtree?
What is the argument in java?
Why multiple inheritance is not supported by java?
What is size_t?
What is mutable object and immutable object?
What is local class in java?
What are the different types of garbage collectors in java?
Does java support Operator Overloading?
What are recursive functions?