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 / john

@Uday Ur fooling amateur coders by creating an anonymous
class within the class . U cannot create an instance of an
Interface .If so try to make execute this code lol class

interface Test{
public void wish();
}
class Main
{
public static void main(String[] args)
{
Test t=new Test();
t.wish();
}
public void wish()
{
System.out.println("output: hello how r u");
}
}

Is This Answer Correct ?    12 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is the empty set a singleton?

972


What is a programming object?

1099


What are the types of methods in java?

1112


What are synchronized methods ?

1109


What is the purpose of the System class?

994


Why does abstract class have constructor?

995


How do you use spaces in java?

987


Differentiate between run time error and syntax error.

1119


Write a function to print Fibonacci series and Tribonacci series?

1178


How to find the given number is a prime number or not by getting input from the user

1094


Explain what do you mean by functional overloading in java?

1011


Which of the following is not an isolation level in the JDBC

2121


hr interview how many minutes asking question

2042


Is vector ordered in java?

994


When should I use a singleton?

1035