VocabularykernelInputs and outputs| obj1 | a generalized boolean |
| obj2 | a generalized boolean |
| ? | a generalized boolean |
Word descriptionIf both inputs are false, outputs
f. otherwise outputs the first of
obj1 and
obj2 which is true.
NotesThis word implements boolean inclusive or, so applying it to integers will not yield useful results (all integers have a true value). Bitwise inclusive or is the
bitor word.
ExamplesUsually only the boolean value of the result is used, however you can also explicitly rely on the behavior that the result will be the first true input:
USING: kernel prettyprint ;
t f or .
t
USING: kernel prettyprint ;
"hi" 12.0 or .
"hi"
Definition