Building useful clases help


Traceback (most recent call last):
File "python", line 8, in
File "python", line 3, in init
TypeError: 'int' object is not iterable

i feel like my code is correct, what am i doing wrong?

    def __init__(self, x, y, z):
        selx,x = x
        self.y = y
        self.z = z
    def __repr__(self):
        return "(%d, %d, %d)" %(self.x, self.y, self.z)
my_point = Point3D(1, 2, 3)
print my_point.__repr__()


This line:

selx,x = x

i see two problems in this line, do you see them as well?


Thank you, i didn't see the typo because of the lighting


the error message:

File "python", line 3, in init

gave you the line which needed a closer look, all good now?


Yup, thanks for everything!