Why does
System.out.println(0100);
print 64 to the console?
Its not like its converting to binary.
An integer starting with a 0 is interpreted in base 8 (as starting with 0x gives you base 16). Thus 0100
is 100
in base 8, which is 1 * 8^2 = 64
.