+ 1
Why (5//2)=2
Help me plese
4 Answers
+ 6
There are 3 division operators:
/-division
//-floor division
%-modulus
5/2==2 with a remainder of 1
5//2==2 (leaving out remainder)
5%2==1(the remainder)
+ 4
// is integer division
Using / will turn it into float by default in python
10 / 2 = 5.0
10 // 2 = 5
+ 3
https://www.sololearn.com/learn/JUMP_LINK__&&__Python__&&__JUMP_LINK/2273/
Have a look at this it might help you out!
+ 3
// is the Python operator for integer or floor division. In C for example you would use / with integer arguments.