How do I get a decimal value when using the division operator in Python?

前端 未结 13 2025
旧巷少年郎
旧巷少年郎 2020-12-01 06:18

For example, the standard division symbol \'/\' rounds to zero:

>>> 4 / 100
0

However, I want it to return 0.04. What do I use?

13条回答
提交回复
热议问题