what is the difference b/w abstract and interface?
Answers were Sorted based on User's Feedback
Answer / n.suresh
Abstract can,t support multiple inheritence.
Interface can suppport the multiple inheritence.
Abstract have accesbulity modifiers.
Interface have no accesbulity modifiers.
| Is This Answer Correct ? | 11 Yes | 0 No |
Answer / bhaskar.mantrala
Interfaces are same as classes but their methods are
declared with out any body..... and definition
corresponding to that allmethods will write on
implementation class(i.e)single class.BUT
Eg:
interface interfacename
{
//Declarations only
//first method
//second method
..
..
//n-th method
//final variables
}
class classname implements interfacename
{
//Definitions of ALL methods present in interfacename
}
Abstract class also has same as interface and definitions of
all those methods may not be present in single extended class.
And we doesn't create an object to class that is abstract.
| Is This Answer Correct ? | 3 Yes | 1 No |
How many types of access specifier in c# and vb.net?
some one give d clear explanation for polymorphism
What is abstraction in oop with example?
What is the difference between the C & C++?
Why is polymorphism needed?
what is a virtual class?
5 Answers Cap Gemini, IBM, Infosys, Trinity Technologies,
why c++ is called OOPS? waht is inherutance? what is compiler?
What is OOPS and How it is different from Procedural Programming ?
23 Answers HP, Infosys, Thyrocare,
Why is polymorphism used?
different types of castings
can we create and enter the data & hide files using programmes ?
Explain virtual inheritance?