Python - Magic Methods and Operator Overloading
Find the error in this code that tries to overload the multiplication operator (*) for a class:
class Multiplier:
def __init__(self, num):
self.num = num
def __mul__(self, other):
return self.num * other.num
m1 = Multiplier(3)
m2 = Multiplier(4)
print(m1 * m2)