+ 2
What is the difference between 5/3 and 5//3 in python?
3 Respuestas
+ 6
5/3 = 1.666666 (normal division)
5//3 = 1 (floor division, returns a whole number)
+ 1
In python3 5/3 is a floating point number (1,6666...) and 5//3 an integer (1).
+ 1
Thank you guys