Interface and abstract classes

when can i use interfaces and when can i use abstract classes.which one is the best choice and why ?

sankar.nvss
Views: 3977 | Community Opinion: 2

Tags..  OOPS Concept  Object Oriented Programming  C# Interview

Bookmark this page..



Ask a New Question Go to Home

Community Opinion/Answers
 

If you need to change your design, make it an interface. However, you may have abstract classes that provide some default behavior. Abstract classes are excellent candidates inside of application frameworks.

Abstract classes let you define some behaviors; they force your subclasses to provide others. It means for abstract classes some implementation should be common although you can override it. Use interfaces if you see different implementation for all implementing classes.




Bharti Said..

hi friends below link provides your answer of above questions and many more concept and questions on csharp and oops and there questions and answer
www.interviewqsn.com/what-is-difference-between-abstract-class-and-an-interface.html
www.getproductprice.com






What do you think? Add your opinion/answer
*Name
*your opinion/answer: