+ 2

Division (/) vs Floor Division (//)?

im going back through basics to help further understand material in more advanced topics of python and i never really thought about it till now but whats the difference between the 2?

6th Apr 2017, 11:11 PM
Seth T
Seth T - avatar
2 Answers
+ 6
Floor division divides, and if the division returns decimal points, it rounds down to the nearest whole number. (or one decimal place)
6th Apr 2017, 11:38 PM
Wen Qin
Wen Qin - avatar
+ 4
ahhhh i feel you so 20 / 6 = 3.3333..., but 20 // 6 = 3.
6th Apr 2017, 11:49 PM
Seth T
Seth T - avatar