Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
12
Task/Bitwise-operations/XPL0/bitwise-operations.xpl0
Normal file
12
Task/Bitwise-operations/XPL0/bitwise-operations.xpl0
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
Text(0, "A and B = "); HexOut(0, A and B); CrLf(0); \alternate symbol: &
|
||||
Text(0, "A or B = "); HexOut(0, A or B); CrLf(0); \alternate symbol: !
|
||||
Text(0, "A xor B = "); HexOut(0, A xor B); CrLf(0); \alternate symbol: |
|
||||
Text(0, "not A = "); HexOut(0, not A); CrLf(0); \alternate symbol: ~
|
||||
Text(0, "A << B = "); HexOut(0, A << B); CrLf(0);
|
||||
Text(0, "A >> B logical = "); HexOut(0, A >> B); CrLf(0);
|
||||
Text(0, "A >> B arithmetic = "); HexOut(0, A ->> B); CrLf(0);
|
||||
|
||||
\Rotate operations must be done by calling a function such as:
|
||||
func ROR(A, B); int A, B; return A>>B ! A<<(32-B);
|
||||
|
||||
Text(0, "A ror B = "); HexOut(0, ROR(A,B)); CrLf(0);
|
||||
Loading…
Add table
Add a link
Reference in a new issue