tfm@europe.pub to Programmer Humor@lemmy.mlEnglish · 1 day agoPython!lemmy.mlimagemessage-square52fedilinkarrow-up1654arrow-down112
arrow-up1642arrow-down1imagePython!lemmy.mltfm@europe.pub to Programmer Humor@lemmy.mlEnglish · 1 day agomessage-square52fedilink
minus-squareOriel Jutty :hhHHHAAAH:@infosec.exchangelinkfedilinkarrow-up2·10 hours ago$ python3 -c 'f = (lambda x: x + 0.5 - 0.5); print(f(2**52))' 4503599627370495.5 #python
minus-squareCevilia (she/they/…)@lemmy.blahaj.zonelinkfedilinkEnglisharrow-up6·8 hours agoAhh, contrived examples of floating point errors. I haven’t seen those since I asked Javascript to add 0.1 and 0.2 :)
$ python3 -c 'f = (lambda x: x + 0.5 - 0.5); print(f(2**52))' 4503599627370495.5
#python
Ahh, contrived examples of floating point errors. I haven’t seen those since I asked Javascript to add 0.1 and 0.2 :)