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...

can you create interface instance ?

Answer Posted / naresh jangili

no we can't create an object to interface and also abstract because two classes are un implememnted class for every un implemented classes we can create only reference varable.
but for every implemented classes we can create objects.
eg: interface A{
public void test()
}
class B implementes A
{
public void test()
{
s.o.p("hello");
}
public static void main(String argss[])
{
B b=new B(); (object creation)
A a1=null; (reference variable)

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Java is pass by value or pass by reference? Explain

994


What is wrapper class html?

944


Write a function to print Fibonacci series and Tribonacci series?

1184


What is the exact difference in between unicast and multicast object? Where we will use?

999


Does java initialize arrays to zero?

1039


What is the use of protected in java?

1027


Difference between current previous versions of Java?

1028


Explain creating threads by extending thread class ?

1057


What is callable java?

983


Explain the term virtual machine?

1052


What are data types in oop?

1037


What is the difference between notify and notifyall method?

1223


What is method and methodology?

1102


Can a private method of a superclass be declared within a subclass?

1043


What is the maximum size of list in java?

976