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 we instantiate Interfaces?

Answer Posted / bharat vandar

No we can instantiate interface directly.but we can create
instantiate of interface in directly,only class can create
an object of interface


interface x
{
public void abc();
}
class ac implements x
{
x at = new ac();

public void abc()
{
System.out.println("Bharat");
}
}

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can we define private and protected modifiers for variables in interfaces?

1088


What is ‘has a’’ relationship in java?

1222


Is java good for beginners?

1018


What happens if we don’t override run method ?

1006


How many types of exception can occur in a java program?

988


What is comparator in java?

1004


Java is pass by value or pass by reference? Explain

994


Can we pass a primitive type by reference in java? How

936


what is ststic with example

2051


What is meant by class loader? How many types are there?

1254


When is finally block not called?

1093


How is abstraction implemented in java ?

1021


What is the purpose of return statement?

1064


If you are given the name of the function at run time how will you invoke the function?

1135


Can long be null in java?

1024