我使用了Fermat的Little Theorem,发现40 ^ 65%7 = 3.但是当我在Python中使用以下代码时,它打印的答案是2.0:
print((math.pow(40,65) % 7))
为什么Python将结果错误地指定为2.0?
谢谢