Answer Posted / nsiddiqui69@yahoo.com
Interface inf1
{
void show();
}
class Derived implement inf1
{
void show1()
{
S.o.p("Derived class method");
}
public void show()
{
S.o.p("Interface method");
}
}
class infdemo
{
p.s.v.m(String args[ ])
{
Derived d1= new Derived();
d1.show();
d1.show1();
}
}
| Is This Answer Correct ? | 5 Yes | 1 No |
Post New Answer View All Answers
Can a string be null?
What are the different types of java?
Why is method overloading not possible by changing the return type in java?
how to split string in java?
How do you use parseint in java?
What is constructor and its types?
What are alternatives to java serialization?
Is heap stored in ram?
What is nan in java?
Can Exception handling we can handle multiple catch blocks?
What are the different conditional statements?
Give the hierarchy of inputstream and outputstream classes.
How many bits is a string?
Define Multiprogramming and Multiprocessing in java.
How do you escape sequences in java?