In this python basic program, we will calculate the area of a circle.
Steps to solve the program
- Take the radius of the circle as input through the user.
- Calculate the area of a circle using the following formula: Pi*r*r, where pi is equal to 3.14 and r is the radius of the circle.
- Print the output.
radius = int(input("Enter radius of circle: "))
area = 3.14*radius*radius
print("Area of circle: ",area)
Output :
Enter radius of circle: 4
Area of circle: 50.24