Skip to content

Math.Mod

Name Mandatory Description Default Type
⬅️ Input The value or the sequence of values to divide the value specified in the Operand parameter with. IntInt2Int3Int4Int8Int16FloatFloat2Float3Float4Color[Any]
Output ➡️ This shard outputs the result of the modulus operation. IntInt2Int3Int4Int8Int16FloatFloat2Float3Float4Color[Any]
Operand No The value or sequence of values to divide the input by and get the remainder of. 0 IntVar(Int)Int2Var(Int2)Int3Var(Int3)Int4Var(Int4)Int8Var(Int8)Int16Var(Int16)FloatVar(Float)Float2Var(Float2)Float3Var(Float3)Float4Var(Float4)ColorVar(Color)[Any]Var([Any])

This shard calculates the remainder of the division of the input value by the value provided in the Operand parameter.

Examples

1
2
@i4(1 2 3 4) | Math.Mod(Operand: @i4(2 2 2 2)) | Log
Assert.Is(@i4(1 0 1 0) Break: true)

[info] [sample-wire] @i4(1 0 1 0)