Working with binary numbers
Numbers can also be provided in binary and hexadecimal formats, using the 0x
and 0b
prefixes respectively.
input = 0xc0e0_0000 input = 0b1111 0000 1111
Results also can be displayed in hexadecimal and binary forms as well.
To switch between them, stand on the given line and press ALT ← or ALT →.
# Write your input here input = 0xc0e00000 // use ALT+(Left|Right) while // the cursor is on the above line // to change to hex or binary representation # interpreting input as... ## ...several unsigned data types input & 0xFF // u8 input & 0xFFFF // u16 input & 0xFFFFFFFF // u32 input & 0xFFFFFFFFFFFFFFFF // u64 ## ...file sizes / number of bytes input = input bytes input in kilobytes input in MB input in GB // ... *ibi-bytes input in KiB input in MiB input in GiB
Developers can use their loved operators as well
bit shifting 0b0001 << 4 (0b1100 & 0b0011) | 0x08 & ~1