Sample Input : a = 3 b = 4 c = 5
i need to pass only number(3,4,5) without a=,b=,c= ..
how to do it?
class Triangle:
def __init__(self,a,b,c):
self.a=a
self.b=b
self.c=c
def perimeter(self):
output = self.a + self.b + self.c
return 'Perimeter is = {}'.format(output)
def area(self):
s = (self.a+self.b+self.c)/2
output = s*(s-self.a)*(s-self.b)*(s-self.c)
return 'Area is = {}'.format(output**0.5)
triangle =Triangle(int(input()),int(input()),int(input()))
triangle.area()
triangle.perimeter()