Can anyone help me in writing code for calculating area of a circle. Using C# | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Can anyone help me in writing code for calculating area of a circle. Using C#

1st Jan 2022, 3:08 PM
Anjali Pandey
2 Answers
+ 7
Chan Jia Min , you are showing a really nice code to help someone solving a task. we all appreciate this very much!  (this is my personal statement - but it is not to criticize someone !!) but there is an issue by giving a ready solution, when the op has not done and shown his attempt first. as a part of the community i believe that learning by doing is more helpful, than just using a shared solution. we should act more as a mentor. it is a very successful way when we are giving hints and help, so that the op is able to solve his task by himself. it would be great if you are going to help us to keep sololearn what it is. thanks for your understanding
1st Jan 2022, 3:57 PM
Lothar
Lothar - avatar
+ 2
It's pretty simple. Do leave a comment if u need any help on the code. static void Main(string[] args) { Console.WriteLine("Radius of circle: "); double r = Double.Parse(Console.ReadLine()); Console.WriteLine("Area of circle: " + Math.PI*Math.Pow(r,2)); }
1st Jan 2022, 3:26 PM
Chan Jia Min
Chan Jia Min - avatar