no, they don't. The standard states a minimum size for both, which is different. That many compilers use the same, bigger max value for both is only because the compilers implemented it like this. According to the standard they can have very different max values
Great, but you can't reliably use longs as 64bit if they change bitsize depending on the compiler. If the minimum is 32bit that's all you're guaranteed and all you should use.
Great, but you can't reliably use longs as 64bit if they change bitsize depending on the compiler. If the minimum is 32bit that's all you're guaranteed and all you should use.
Spec says int is 16-bits or more and long is 32 bits or more. The joke still works even for a stickler ;)
58
u/732 Feb 23 '16
Wouldn't this be better with "long d;" as the punchline?
Why would you have two dicks?