using System;
class Geometrical_Shapes
{
double Area;
string Shape;
string Color;
public void GetInput ()
{
Console.Write("Enter the name of the shape: ");
Shape = Console.ReadLine();
Console.Write("Enter the Color: ");
Color = Console.ReadLine();
Console.Write("Enter the Area: ");
Area = Convert.ToDouble(Console.ReadLine());
}
public void Display()
{
Console.WriteLine();
Console.WriteLine("THIS IS WHAT YOU ENTERED: \n");
Console.Write("Name of the Shape: ");
Console.WriteLine(Shape);
Console.Write("Color: ");
Console.WriteLine(Color);
Console.Write("Area: ");
Console.WriteLine(Area);
}
}
class Classy
{
static void Main(string[] args);
Geometrical_Shapes Small_rectangle = new Geometrical_Shapes ();
Small_rectangle.Create();
small_rectangle.Display();
Console.ReadLine();
}
No comments:
Post a Comment