成功解决TypeError: 'float' object cannot be interpreted as an integer
目录
解决问题
解决思路
解决方法
解决问题
TypeError: 'float' object cannot be interpreted as an integer
解决思路
类型错误:“float”对象不能解释为整数
解决方法
python2和python3中运算符的区别 查看代码中是否含有/, python3的/结果含有浮点数! python2中的/等价于python3的// 在python3中,//表示取整除 - 返回商的整数部分(向下取整)
print(5/2,5//2) #输出2.5 2