Sleepless One@lemmy.ml to Programmer Humor@lemmy.mlEnglish · 1 day agoThe JavaScript type coercion algorithmlemmy.mlimagemessage-square42fedilinkarrow-up1106arrow-down12file-textcross-posted to: programmer_humor@programming.dev
arrow-up1104arrow-down1imageThe JavaScript type coercion algorithmlemmy.mlSleepless One@lemmy.ml to Programmer Humor@lemmy.mlEnglish · 1 day agomessage-square42fedilinkfile-textcross-posted to: programmer_humor@programming.dev
minus-squareMidnitte@beehaw.orglinkfedilinkEnglisharrow-up7arrow-down1·edit-21 day ago3 - 1 // -> 2 3 + 1 // -> 4 '3' - 1 // -> 2 '3' + 1 // -> '31'
3 - 1 // -> 2
3 + 1 // -> 4
'3' - 1 // -> 2
'3' + 1 // -> '31'