# XOR

Result = Expression XOR Expression

Computes the logical exclusive or of two expressions.

Examples

    PRINT TRUE XOR FALSE

    True

    PRINT TRUE XOR TRUE

    False

    PRINT 7 XOR 11

    12

    PUBLIC SUB Form_Open()

      DIM a AS Boolean
      DIM b AS Boolean

      FOR a = 0 TO 1
        FOR b = 0 TO 1
          PRINT a, b, a XOR b
        NEXT
      NEXT

    END

See also

AND, BChg, BClr, BSet, BTst, NOT, OR, Rol, Ror, Shl, Shr

Previous: WRITE Next: Year