OR (boolean)

From QB64 Wiki
Revision as of 23:58, 9 May 2011 by imported>Clippy
Jump to navigation Jump to search

The OR coditional operator adds an alternative in a IF...THEN or Boolean statement.

  • OR adds an alternative to another conditional evaluation. IF True then the statement evaluation is True.
  • Parenthesis may be used to clarify an evaluation.
  • Can be confused with the OR numerical operator.


a% = 100 b% = 50 IF (a% > b% AND a% < 100) OR b% = 50 THEN PRINT "True"


Explanation: The first evaluation was False, but the OR evaluation made the statement true and the code was executed.

See also:

Go to Keyword Reference - Alphabetical
Go to Keyword Reference - By usage
Go to Main WIKI Page