小编gau*_*av 的帖子

比较int和float时Python什么时候进行类型转换?

为什么Python中返回True时,我比较intfloat具有相同价值的物品?

例如:

>>> 5*2 == 5.0*2.0
True
Run Code Online (Sandbox Code Playgroud)

python floating-point int python-3.x python-internals

8
推荐指数
1
解决办法
3005
查看次数