Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

WAP to illustrate the use of interface

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


Please Help Members By Posting Answers For Below Questions

What is the difference between static method and instance method in Java?

1134


what is recursion in java

1079


What is a char in java?

982


how to create constants in java?

1039


What is the difference between JVM and JRE?

1044


What is r in java?

999


Can you explain the meaning of aggregation and composition

941


How can you read content from file in java?

964


How does compareto work in java?

985


Why do we need array in java?

960


What is the difference between delete and delete[]

1413


Is java hard to learn?

866


What does n mean?

937


What are the access modifiers available in java?

1063


What are the 5 types of research methods?

1087