<< Home | About Forth | About TurboForth | Download | Language Reference | Resources | Tutorials | YouTube >>


/MOD Search:

In Math Words in TurboForth Kernal

Word Name: /MOD
Type: Standard word
Data Stack Signature: n1 n2 -- n3 n4
Return Stack Signature: --
Availability: V1.0  V1.1  V1.2
Description:

n3 is the remainder and n4 the floor of the quotient of n1 divided by the divisor n2.

Example:

none

Comment:

n3 has the same sign as n2 or is zero. An error condition results if the divisor is zero or if the quotient falls outside of the range {-32,768..32,767}.

See Also: / 

<< Home | About Forth | About TurboForth | Download | Language Reference | Resources | Tutorials | YouTube >>