What Does Double Slash Operation // Do In Python?
What is the double slash operator and what does the double slash operator // do in Python? The double slash operator in Python returns the quotient value from a division operation. The operator requires two numbers: a dividend and a divisor, which are the same numbers used with standard division operations in mathematics. For example, the mathematical expression 75 ÷ 10 has the 75 as the dividend, 10 as the divisor and returns the value 7 as quotient and 5 remainder. Therefore, when the double slash operator is used in Python on the same mathematical calculation the result will be just 7, as seen in the Python REPL below: ...