* remember to give an explanation * XOR vs OR a b OR -----|---- 0 0 | 0 0 1 | 1 1 0 | 1 1 1 | 1 a b XOR -----|---- 0 0 | 0 0 1 | 1 1 0 | 1 1 1 | 0 xor rax, rax ; A <- 0 A - B = A + (-B) To get -B, use 2's complement B = 10101011 1's comp of B 01010100 2's comp of B + 1 --------- 0000000 01010100 + 1 --------- 01010101 = -B Suppose that myBytes is stored at 0000. How do you tell the computer that you want 12 and not 0000? mov ax, myBytes ; put the address (0000) into ax max ax, [myBytes] ; put the value (12) into ax address memory value 0000 12 0001 03 0002 34 0003 45 0004 5F 0005 67 0006 78 ... FFFE FFFF