English, asked by 0DIVINESOUL0, 1 month ago

Write a Python programme that accept radius of circle from Python Shell and calculate area of circle.

No Spam... xd​

Answers

Answered by XxItzMeTannuXx
5

Explanation:

Area of a Circle is givem by:

\sf Area = \pi\times radius^2Area=π×radius

2

So we have to take an input of the value of radius, compute the value of area and print it accordingly.

We need the value of \piπ too. We can set its value as 22/7 or 3.1416 approximately.

Or we can use the pi available in the math module.

Here is a sample program which accomplishes the task:

#Program to calculate Area of Circle

from math import pi

#Or we can set pi=3.1416 approximately

radius = float(input("Enter the radius: "))

area=pi*radius*radius

print("Area of the circle is",format(area,'.3f'),"sq units")

The format command with '.3f' rounds off the value of area to three decimal places.

Answered by XxbengalqueenxX
3

Answer:

m fine how r u

Explanation:

yaah I had my breakfast

Similar questions