+ 8
Quotient: A quotient is the result of performing a division. This is nothing that is related to python only, this is simply math. This is the modulus operator. It does perform a division, but does not show the quotient but the remainder. 10 % 4 gives 2 10 / 4 gives 2. so 4 * 2 gives 8 and there is a remainder of 2 upto 10. 10 / 3 = 3 1 Dividend / Divisor = Quotient Remainder If you need both, remainder and quotient with the same values as a base, you can use also divmod(num1, num2). It returns a tuple with the quotient and the remainder.
8th Dec 2019, 6:12 PM
Lothar
Lothar - avatar