Jan-09-2019, 01:14 AM
In most programming languages (Python 2 included), dividing two integers results in "integer division" which mean that the floating point part is just discarded and you end up with an integer. In Python 3, division works as you would expect. Further, any computations that involve a floating point number will result in a floating point number. In theory Python could give you an integer, since your floating point number is an integer, but it doesn't.