In the US (and afaik all non JPY, KRW currencies), we’re cursed with fractional currencies. We can pay $1.49 for a candy bar. So if we want to represent that in code, the obvious thing is to use floats x = '1.49' Great. Right? Right?
Don't serialize money as a float
Don't serialize money as a float
Don't serialize money as a float
In the US (and afaik all non JPY, KRW currencies), we’re cursed with fractional currencies. We can pay $1.49 for a candy bar. So if we want to represent that in code, the obvious thing is to use floats x = '1.49' Great. Right? Right?