static void Main(string[] args) { BaseballPlayer dude = new BaseballPlayer(); WoodenBat woodenBat = new WoodenBat(); AluminumBat alum = new AluminumBat(); dude.TakeTurn(woodenBat); dude.TakeTurn(alum); }
static void Main(string[] args) { var woodenBat = new WoodenBat(); var aluminumBat = new AluminumBat(); //var hank = new BaseballPlayer(); var compositeBat = new CompositeBat(); var jack = new CricketPlayer(); //hank.TakeTurn(woodenBat); //hank.TakeTurn(aluminumBat); //hank.TakeTurn(compositeBat); jack.TakeTurn(woodenBat); jack.TakeTurn(aluminumBat); jack.TakeTurn(compositeBat); }
static void Main(string[] args) { BaseballPlayer hank = new BaseballPlayer(); CricketPlayer courtney = new CricketPlayer(); WoodenBat woodenBat = new WoodenBat(); AluminumBat aluminumBat = new AluminumBat(); CompositeBat compositeBat = new CompositeBat(); CricketBat cricketBat = new CricketBat(); hank.TakeTurn(woodenBat); hank.TakeTurn(aluminumBat); hank.TakeTurn(compositeBat); Console.WriteLine(); courtney.TakeTurn(cricketBat); Console.WriteLine(); }