+ 1

what is floor division?

20th Aug 2018, 5:37 AM
sadi
5 Answers
+ 2
n//d = n/d rounded to the integer just below (floor) the result. https://code.sololearn.com/cN4gPuhaXnbX/?ref=app
20th Aug 2018, 5:39 AM
davy hermans
davy hermans - avatar
+ 2
Steppenwolf that is exactly what i mean by 'to the integer just below.' (ex -5//3=-2 and -5//4=-2) I probably shouldn't have used the word round.
20th Aug 2018, 11:48 AM
davy hermans
davy hermans - avatar
+ 1
Floor division means ______ 3 | 17 |5 ------ 15 ------ 2 17//3 here we using floor division in floor division we use // sign here answer of floor division is 5 and remainder is 2.
20th Aug 2018, 11:16 AM
Maninder $ingh
Maninder $ingh - avatar
+ 1
davy hermans Oh, right. I haven't noticed that "below" 🙂 factually, "round" is a little bit misleading
20th Aug 2018, 1:07 PM
Steppenwolf
Steppenwolf - avatar
0
davy hermans That's not true. Floor division is a truncated result, not rounded. 6 // 3 = 2 --> 6 / 3 = 2.0000 7 // 3 = 2 --> 7 / 3 = 2.3333 8 // 3 = 2 --> 8 / 3 = 2.6667 9 // 3 = 3 --> 9 / 3 = 3.0000
20th Aug 2018, 10:40 AM
Steppenwolf
Steppenwolf - avatar