IMP - mkilgore/QB64pe GitHub Wiki
The IMP logical operator converts the result of two comparative values and returns a bit result.
- result = firstValue IMP secondValue
- Returns a different result from AND, OR or XOR - see truth table below.
- Evaluates if firstValue implies secondValue.
- If firstValue is true then secondValue must also be true.
- So if firstValue is true, and secondValue false, then the condition is false, otherwise it is true (see table below).
The results of the bitwise logical operations, where A and B are operands, and true or false indicate whether a bit is set or not set:
| ||||||||||||||||||||||||||||||||||||||||||||||||
Relational Operations return negative one (-1, all bits set) and zero (0, no bits set) for true and false, respectively. This allows relational tests to be inverted and combined using the bitwise logical operations. |
Navigation:
Go to Keyword Reference - Alphabetical
Go to Keyword Reference - By usage
Go to Main WIKI Page