Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace Shapes
- {
- public class StartUp
- {
- static void Main(string[] args)
- {
- Shape rectangle = new Rectangle(5, 19);
- Shape circle = new Circle(5);
- Console.WriteLine(rectangle.Draw());
- Console.WriteLine($"Perimeter: {rectangle.CalculatePerimeter():F2}");
- Console.WriteLine($"Area: {rectangle.CalculateArea():F2}");
- Console.WriteLine(circle.Draw());
- Console.WriteLine($"Perimeter: {circle.CalculatePerimeter():F2}");
- Console.WriteLine($"Area: {circle.CalculateArea():F2}");
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement