can you create interface instance ?

Answer Posted / anonymous

Hi Uday,

That's really nice however I think you have just created and anonymous class implementing the interface, and then invoking the wish method :)

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Define locale.

588


How to remove the trailing spaces from a string?

652


How is string stored in java?

558


Can we write class inside a class in java?

550


Can we catch more than one exception in single catch block?

599






Difference between abstract and concrete class ?

581


How do you sing an Applet ?

2030


Enlist few advantages of inheritance?

582


What does serializing data mean?

523


Can a method be static?

522


How to declare objects of a class ?

587


What is java command?

569


What modifiers are allowed for methods in an interface?

646


Can we force the garbage collection to run?

534


What’s the difference between applets and standalone program?

532