Class it up


I don't understand why i get this mistake?

Like, I put self as argument for the method, no?

thanks in advance for your help!!


In your check_angles() method you shouldn't have angle1, angle2 and angle3 passed in as arguments because you're not referencing them, you're referencing self.angle1 etc. In other words, self should be the only argument.

As for the actual error, I imagine the SCT (Submissions Correctness Test) is checking that the method only contains self, hence the somewhat misleading message.


ahhhhhhh!!! okok yeah i thought it was somewhat ineffective to remind the angleX arguments.

Thanks a lot for your answer!


Why it is incorrect to write:
if sum(self.angle1, self.angle2, self.angle3) == 180:
I thought it would be the same as: if self.angle1 + self.angle2 + self.angle3 == 180:
but it is wrong.


sum() takes an iterable (such as a list or dict) as its argument, for example sum([x, y, z])


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.