Ejemplo n.º 1
0
 public string Drive(IDrive person)
 {
     // starting a car is the responsibility of
     // a Person, so that method is on the Person class
     person.StartCar();
     return("i drove");
 }
Ejemplo n.º 2
0
 static public void Drive(IDrive driver)
 {
     driver.StartCar();
 }