Modulo

logic · C066 · starter-package 7.0.1

Returns the remainder after dividing one finite number by a non-zero finite divisor. This block follows JavaScript remainder semantics: the result's sign follows the dividend.

Inputs

  • Dividend (number, required): Value to divide.
  • Divisor (number, required): Finite non-zero divisor.

Output

  • Result (number): Signed remainder.

Common uses

Detect even or odd values, wrap counters, distribute work across groups, or find leftover units after full batches.

Example

Dividend 17 and Divisor 5 produce 2; -17 and 5 produce -2.

Errors and recovery

When this block reports an error, no downstream output is emitted. Correct the highlighted input or setting described by the message, then run the workflow again.

Zero division, missing values, invalid numeric text, NaN, and infinities are rejected.

Connector data types

The type below is the data type that actually travels through the connection. Any additional validation is described separately in this block guide.

DirectionConnectorTypeRequired
Inputdividend — Dividendnumberyes
Inputdivisor — Divisornumberyes
Outputresult — Resultnumberon success