Back to functions

mod


mod

Calculates the modulo of two numbers.

Usage: nerdamer("mod(x, y)")


Parameters

expression x Returns the appropriate value if possible otherwise it returns the function with the simplified expression
expression y Returns the appropriate value if possible otherwise it returns the function with the simplified expression

Returns

Expression

EXAMPLES:
var x = nerdamer('mod(5, 2)').evaluate();
console.log(x.toString());
x = nerdamer('mod(10/12, 1/2)');
console.log(x.toString());
OUTPUT:
Back to functions