violet08_@lemmy.world to Lemmy Shitpost@lemmy.world · 4 days agowow😰lemmy.worldimagemessage-square40linkfedilinkarrow-up1311arrow-down113
arrow-up1298arrow-down1imagewow😰lemmy.worldviolet08_@lemmy.world to Lemmy Shitpost@lemmy.world · 4 days agomessage-square40linkfedilink
minus-squarekkj@lemmy.dbzer0.comlinkfedilinkEnglisharrow-up12·4 days ago-2,147,483,649, actually. A signed int32 can represent -1 just fine.
minus-squarekkj@lemmy.dbzer0.comlinkfedilinkEnglisharrow-up4·4 days agoUnsigned jumps from 0 to 4,294,967,295. An overflow won’t get you to 2,147,483,647 unless you have a 31-bit uint for some reason.
minus-squarelad@programming.devlinkfedilinkEnglisharrow-up3·4 days agoHaving integers with amount of bits indivisible by 2, let alone 8, is a nice feature to have in a language, I deed
minus-squareValmond@lemmy.dbzer0.comlinkfedilinkarrow-up2·3 days agoint a:7; IIRC (C/C++). But doesn’t overflow as you’d expect.
-2,147,483,649, actually. A signed int32 can represent -1 just fine.
Yeah, unsigned ofc.
Unsigned jumps from 0 to 4,294,967,295. An overflow won’t get you to 2,147,483,647 unless you have a 31-bit uint for some reason.
Having integers with amount of bits indivisible by 2, let alone 8, is a nice feature to have in a language, I deed
int a:7;
IIRC (C/C++). But doesn’t overflow as you’d expect.