Contents | Prev | Next | Index
OR | logical disjunction | p OR q == "if p then TRUE, else q end" |
AND | logical conjunction | p AND q == "if p then q, else FALSE end" |
& | logical conjunction | p & q == "if p then q, else FALSE end" |
NOT | negation | NOT p == "not p" |
~ | negation | ~p == "not p" |
These operators can be applied to BOOLEAN operands only and yield a BOOLEAN result.
If the language extensions are enabled via a compiler switch or directive then the following logical operator is also available:
XOR | exclusive or | p XOR q == "if p and not q then TRUE, else not p and q" |
Contents | Prev | Next | Index
Canterbury Modula-2 for Java (Last documentation update
Feb 8, 2000)
Copyright © 1998 Mill Hill &
Canterbury Corporation, Ltd. All rights reserved
Please send any comments or corrections to
mhc@webcom.com