0
Module - calculating circle perimeter and area
Can someone see why I keep getting errors on my code?
2 ответов
+ 5
You have to return the variable
instead of return do return perim
And return area
- 1
from math import pi
radius = int(input())
def perim():
perim = 2 * pi * radius
return
def area():
area = pi * radius * radius
return
print("Perimeter:", round(perim(), 2))
print("Area:", round(area(), 2))