Question: why count_to=100/99 is 1 in Python?



why count_to=100/99 is 1 in Python ?


the division involves two integers, so python will return a integer as well. If needs be, python will just floor (round down) the result

This division behaviour changed in python3.


thank you very much!!!


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.