Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int num = 00000010;
- System.out.println(num);
- int num = 00000100;
- System.out.println(num);
- int num = 00000010 << 1;
- System.out.println(num);
- 00000010 => 1*8^1 + 0*8^0 => 8
- 00000100 => 1*8^2 + 0*8^1 + 0*8^0 => 64
- 00000100 => 00001000
- (8 => 16)
- 0b000010 => 2
Add Comment
Please, Sign In to add comment