The math.remainder() function returns the remainder of two numbers after division. 

Syntax:
math.remainder(x, y)

Where x is the dividend and y is the divisor.

The function returns the remainder as a floating-point number with the same sign as the dividend.

ExampleEdit & Run
import math

print(math.remainder(4, 2))
print(math.remainder(6.5, -2))
print(math.remainder(-6.5, 2))
print(math.remainder(20, 6))
Output:
0.00.5-0.52.0[Finished in 0.010739026125520468s]