Performs a logical bit-wise Or on two bit patterns.
i | j
i %| j
i, j:integer expression
i | j sets only the bits which are set in at least one of the two operands i or j. For completeness with %& (which replaces the & - And operator), the %| operator is added as a replacement for |.
Print Bin$(3, 4) // Prints 0011
Print Bin$(3 | 10, 4) // Prints 1011
Print Bin$(5 %| 10, 4) // Prints 1111
Or is synonymous with | and can be used instead:
Print Bin$(3 Or 10, 4) // Prints 1011
{Created by Sjouke Hamstra; Last updated: 23/09/2014 by James Gaite}