no "continue" in bp 7 commands
[rrq/rrqforth.git] / adoc / p_div.adoc
1 // math.asm:    WORD p_div,'/',fasm
2
3 anchor:p_div[]
4
5 === Word: /
6
7 ....
8 Data stack: ( v1 v2 -- q )
9 ....
10
11 "/" (div) is a function word that replaces a pair of values with the
12 results of signed integer division of the first, v1, divided by the
13 second, v2. To that end, the values are 64-bit signed integers. The
14 result is the integer quotient, q, and the discarded remainder, r,
15 where q and r are the respectively largest and smallest integers to
16 satisfy the formula:
17 ....
18        v1 = q * v2 + r
19 ....