#I am making a program that will calculate area and perimeter or the circle. No errors but the answer is not what I expect it to be.
class Circle:
def __init__ (self):
self.radius = 0
def setRadius(self,radius):
self.radius = radius
def calcArea (self):
self.area = 3.14 * (self.radius ** 2)
def calcCircumference (self):
self.circumference = 2 * (3.14 * self.radius )
def getRadius (self):
return self.radius ()
def getArea (self):
return self.calcArea ()
def getCircumference (self):
self.calcCircumference ()
#My execution
c1 = Circle ()
print("c1.Area",c1.getArea())
c1.setRadius(7)
print("c1.Area",c1.getArea())
#this is the answer I get when I execute it. c1.Area None c1.Area None