What?s the difference between an interface and abstract class?

Answer Posted / rambabu gonela

java does't support multiple inheritance..to overcome this
problem.. java introduce new concept that is interface,
we cannot intantiate both interface and abstractclass.1)by
default in interface variables are public,static and final,
in abstract class we have to declare explicitly 2) methods
in interface public,nonstatic and abstract,where as in
abstract class we have to give....
3)we can implements more than one interfaces.. but we can
extends only one class..

Is This Answer Correct ?    7 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to create multi-dimensional array?

599


Difference between value and reference type.

509


What is default parameter in c#?

504


What is a method c#?

469


Explain the mechanism of VB.NET/C# achieve polymorphism?

535






What does the keyword “virtual” declare for a method or property?

528


Tell me the difference between call by value and call by reference.

534


Does c# have functions?

460


What is the difference between static class and singleton class in c#?

481


What is enumerable in c#?

472


What is the reason behind the invention of c#?

627


What is windows forms in c#?

470


i want o/p 011242110 in c# code.

1628


What do you mean by string objects are immutable?

500


What is the difference between protected and private?

463