>>> class Poly1d(object): ... def __init__(self, power, coeffs): ... self.power = power ... self.coeffs = coeffs ... >>> pol = Poly1d(2, [1,2,3]) >>> pol.power 2 >>> pol.coeffs [1, 2, 3]