For the string magic method of ComplexNumber there's a "# Or, more likely," after the return statement with a way that students would probably code it. For the case where the complex part is negative it returns sign + str(self.imag) but a negative number cast as a string already has a negative sign. So this would print two negative signs.
For the string magic method of ComplexNumber there's a "# Or, more likely," after the return statement with a way that students would probably code it. For the case where the complex part is negative it returns sign + str(self.imag) but a negative number cast as a string already has a negative sign. So this would print two negative signs.