Python Methods and Constructor: What will be output of below code?

Code

class A :
    x = 10
    def __init__(self, y,z):
        self.y = y
        self.z = z
           
    def update_y(self):
        self.y = self.y * self.z

        
        
A1 = A(3,4)
A2 = A(5,6)

A.x = 30
A1.y + A2.x
Tags
programsbuzz banner