mercredi 15 juin 2016

parseInt in JavaScript or AS3 returning wrong value

Can someone please explain why all these parseInt operations evaluate to the same number 10153593963283296?

parseInt('10153593963283294') 10153593963283294

parseInt('10153593963283295') 10153593963283296

parseInt('10153593963283296') 10153593963283296

parseInt('10153593963283297') 10153593963283296

parseInt('10153593963283298') 10153593963283298

Tested in browsers and node command line.


Aucun commentaire:

Enregistrer un commentaire