17 lines
374 B
Text
17 lines
374 B
Text
6 var a 3 var b
|
|
|
|
def tab
|
|
9 tochar print
|
|
enddef
|
|
|
|
def printBits
|
|
8 int>bit reverse print nl
|
|
enddef
|
|
|
|
a print " = " print tab a printBits
|
|
b print " = " print tab b printBits
|
|
tab "------------------------" print nl
|
|
"AND = " print tab a b bitand printBits
|
|
"OR = " print tab a b bitor printBits
|
|
"XOR = " print tab a b bitxor printBits
|
|
"NOT = " print tab a bitnot printBits
|