This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| crpl:docs:xor [2013/01/14 19:01] – created virgilw | crpl:docs:xor [2025/02/14 14:57] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| - | TODO | + | |
| + | <- [[crpl: | ||
| + | ===== xor ===== | ||
| + | |||
| + | xor | ||
| + | |||
| + | === Description === | ||
| + | Pops two items from the stack, treats them as boolean values, ' | ||
| + | |||
| + | If both items are TRUE, 0 is pushed to the stack. If both items are FALSE, 0 is pushed to the stack. If one item is TRUE and the other is FALSE, 1 is pushed to the stack. | ||
| + | === Examples === | ||
| + | <code 4RPL> | ||
| + | TRUE TRUE Trace # | ||
| + | TRUE FALSE Trace #prints out 1 (TRUE) to the tracelog | ||
| + | FALSE TRUE Trace #prints out 1 (TRUE) to the tracelog | ||
| + | FALSE FALSE Trace # | ||