CODE:
using System;
usingSystem.Collections.Generic;
usingSystem.Linq;
usingSystem.Text;
namespaceAreaofCircle
{
classProgram
{
staticvoid Main(string[]
args)
{
int r;
constdouble π = 3.142;
double A;
Console.WriteLine("Please
Enter radius:");
r
= Convert.ToInt32(Console.ReadLine());
A
= π * r * r;
Console.WriteLine(" with
radius {0} the area of circle is {1}", r, A);
}
}
}
No comments:
Post a Comment