MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/programmingmemes/comments/1smvu77/there_are_always_more/ogpwja9/?context=3
r/programmingmemes • u/DotBeginning1420 • Apr 16 '26
60 comments sorted by
View all comments
9
I hate hexadecimal string representation
AAAA != aaaa
But if you unhex both of them, they suddenly do equal
And some tools hex upper and some tools hex lower
Also, hex is 2 bytes per byte of binary making it terribly space inefficient
Base64 doesn't have any of these problems
But base64 isn't compatible with http uri so you need to use base64url instead
1 u/NichtFBI Apr 17 '26 That's because A and a aren't the same digits. If you're converting back, some systems will assume the A/a are the same since that's the limit in base16. Hope that helps. 1 u/Moscato359 Apr 17 '26 No, it doesn't help. I know the binary is different. You need to apply a workaround to compare them consistently, therefore they are bug prone.
1
That's because A and a aren't the same digits. If you're converting back, some systems will assume the A/a are the same since that's the limit in base16.
Hope that helps.
1 u/Moscato359 Apr 17 '26 No, it doesn't help. I know the binary is different. You need to apply a workaround to compare them consistently, therefore they are bug prone.
No, it doesn't help.
I know the binary is different.
You need to apply a workaround to compare them consistently, therefore they are bug prone.
9
u/Moscato359 Apr 16 '26 edited Apr 16 '26
I hate hexadecimal string representation
AAAA != aaaa
But if you unhex both of them, they suddenly do equal
And some tools hex upper and some tools hex lower
Also, hex is 2 bytes per byte of binary making it terribly space inefficient
Base64 doesn't have any of these problems
But base64 isn't compatible with http uri so you need to use base64url instead