Hello All,
What are differences between the following two statements
Sample sobj1 = new Sample();
ISample sobj2 = new Sample();
Sample is a class and ISample is an interface. I could access all members of the class Sample through sobj1 or sobj2, then why I have to define interface and use second statement
Please let me have the right reason
Many Thanks
k.senthilkumaran

why I need to define (impliment) interface?
using Drinks.Vodka.Martini
Here are four great articles and one MSDN Reference about interfaces: