2
當我試圖使用如何圍捕複雜無(1.9999999999999998-2j)如(2-2j)在python
print(round(x,2))
它顯示
Traceback (most recent call last):
File "C:\Python34\FFT.py", line 22, in <module>
print(round(x,2))
TypeError: type complex doesn't define __round__ method
您是否想要實際更改值,或者只是打印它的舍入表示形式? – 2014-09-13 06:14:27
我想改變這個值 – prav 2014-09-13 06:53:39