public void Test() { var circle = new Circle(); var conValueRead = new ConsoleValueReaderX(); circle.CircleRadius = conValueRead.ReadDouble("Wpisz promień koła : "); circle.CircleRadius = circle.Scale(conValueRead.ReadDouble("Podaj współczynnik skalowania : ")); Console.WriteLine("Pole koła to : " + circle.CalculateArea()); Console.ReadKey(); }
public void Test() { var consoleValueReaderX = new ConsoleValueReaderX(); var rec = new Rectangle(); rec.Height = consoleValueReaderX.ReadDouble("Podaj Wysokość Prostokąta :"); rec.Width = consoleValueReaderX.ReadDouble("Podaj Szerokość Prostokąta :"); double calculateArea = rec.CalculateArea(); Console.WriteLine("Pole prostokąta to : " + calculateArea); Console.ReadKey(); }