belongs to collection: C# Language Basic programs with examples
C# Program to Calculate Area of Circle
This program is compiled and tested on a Visual Studio 2012..
using System; namespace TechStudyCSharp { class Program { static void Main(string[] args) { double radius, area; Console.WriteLine("Enter Radius: "); radius = Convert.ToDouble( Console.ReadLine()); area = Math.PI * radius * radius; Console.WriteLine("\nArea of circle: "+area); Console.ReadKey(); } } }
Result:
Enter Radius:
10
Area of circle: 314.159265358979
total answers (1)
start bookmarking useful questions and collections and save it into your own study-lists, login now to start creating your own collections.
This program is compiled and tested on a Visual Studio 2012..
Result:
Enter Radius:
10
Area of circle: 314.159265358979
need an explanation for this answer? contact us directly to get an explanation for this answer