Question 6
What is the output of the following code?
class Box:
def __init__{self, w, h}:
self.w = w
self.h = h
def area(self):
return self.w * self.hb1 = Box(4, 5)
b2 = Box(3, 6)
print(b1.area() + b2.area())
b1.area() = 4 * 5 = 20. b2.area() = 3 * 6 = 18. Total = 20 + 18 = 38.