Re:What even is a JSON number?
by zerocrates on Tuesday April 02, 2024 @01:28PM
(#39908454)
In dollars, what do you get up to with a double of cents without precision loss? It's in the trillions, I figure? So a very large space of applications where smallest-denomination-as-JSON-number is going to be fine.
[ Parent
| on HN ]
Prices can certainly have more decimals that cents.
If you just store cents you can't represent them. You either have to guess at the beginning the smallest unit or store the precision along with it.
Just use strings, it's much simpler.