static void Main(string[] args) { ScoringAlgorithm scoringAlgorithm; Console.WriteLine("Mans"); scoringAlgorithm = new MensScoringAlgorithm(); Console.WriteLine(scoringAlgorithm.GenerateScore(10, new TimeSpan(0, 2, 34))); Console.WriteLine("Woman"); scoringAlgorithm = new WomanScoringAlgorithm(); Console.WriteLine(scoringAlgorithm.GenerateScore(10, new TimeSpan(0, 2, 34))); Console.WriteLine("Children"); scoringAlgorithm = new ChildrenScoringAlgorithm(); Console.WriteLine(scoringAlgorithm.GenerateScore(10, new TimeSpan(0, 2, 34))); Console.ReadLine(); }
static void Main(string[] args) { ScoringAlgortihm Algortihm; Console.WriteLine("Mans"); Algortihm = new MensScoringAlgorithm(); Console.WriteLine(Algortihm.GenerateScore(7, new TimeSpan(0, 2, 14))); Console.WriteLine("Voman"); Algortihm = new WomanScoringAlgorithm(); Console.WriteLine(Algortihm.GenerateScore(7, new TimeSpan(0, 2, 0))); Console.WriteLine("Kids"); Algortihm = new KidsScoringAlgorithm(); Console.WriteLine(Algortihm.GenerateScore(7, new TimeSpan(0, 1, 54))); Console.ReadLine(); }