Is there a definitive solution to javascript floating-point errors?

后端 未结 3 497
無奈伤痛
無奈伤痛 2020-12-19 14:09

I write line of business applications. I\'d like to build a front-end end using Javascript and am trying to figure out how to deal with, for a business user, are floating p

3条回答
  •  囚心锁ツ
    2020-12-19 14:30

    the only definite solution seems to be writing your own arbitrary precision number type working on strings internally -- which will be complicated and horribly slow.

提交回复
热议问题