Home >>Python math Module >Python math.remainder() Method
Python math.remainder() method in python is used to returns the remainder of the first number with respect to the second number in the float of given numbers and , it accepts two numbers (integer or float).
Syntax:math.remainder(x, y)
Parameter | Description |
---|---|
x | It is required a number you want to divide. |
y | It is required a number you want to divide with. |
import math
print (math.remainder(5, 1))
print (math.remainder(14, 10))
import math
x = 12
y = 5
print(math.remainder(x,y))
x = 12.4
y = 5.7
print(math.remainder(x,y))