using System.Collections.Generic;
using System.Threading.Tasks;
namespace GeometricFigures
throw new ArgumentException("Radius can not be less than 1!");
public Circle(int radius)
public double EvaluateSquare()
double square = Math.PI * Radius * Radius;
public static void AskForSide()
Console.WriteLine("Enter the Side for your Rectangle:");
public static int CheckSide1Value()
if (int.TryParse(Console.ReadLine(), out side1))
throw new ArgumentException("Side1 should be an integer");
public static int CheckSide2Value()
if (int.TryParse(Console.ReadLine(), out side2))
throw new ArgumentException("Side2 should be an integer");
private int _side1, _side2;
throw new ArgumentException("Side1 can not be less than 1!");
throw new ArgumentException("Side2 can not be less than 1!");
public Rectangle (int side1, int side2)
public int EvaluateSquare()
int square = Side1 * Side2;
get { return Side1 == Side2; }
public static void Main(string[] args)
InputOutput.AskForSide();
int side1 = InputOutput.CheckSide1Value();
InputOutput.AskForSide();
int side2 = InputOutput.CheckSide2Value();
Rectangle firstRectangle = new Rectangle(side1, side2);
int rectangleResult = firstRectangle.EvaluateSquare();
Console.WriteLine(rectangleResult);
Console.WriteLine("Is your rectangle a square? "+ firstRectangle.IsSquare);
Console.WriteLine(ex.Message);