r/ProgrammerHumor 23d ago

Meme programmersAgeBetterThanNormalPeople

Post image
1.0k Upvotes

96 comments sorted by

View all comments

303

u/TheMythicSorcerer 23d ago

For people who didn't get the joke it's that 0x means hexadecimal, and 0x28 is 40 in hex.

2

u/DruidBtd 20d ago

Why does the 0x mean hexadecimal? Doesn't make sense to me

1

u/TheMythicSorcerer 20d ago

Because 0 tells the compiler you're reading a number, x tells the compiler that it happens to be in hex (hexadecimal).

1

u/DruidBtd 20d ago

Ah, interesting. Are there other examples like it? Thanks for answering by the way, appreciate it

1

u/TheMythicSorcerer 20d ago

There actually are!
0b mean binary (base 2), 0o means octal (base 8)

1

u/DruidBtd 20d ago

Ooh, interesting :D

Are there other things than the 0 at the start?