3 ms·
It's all about costs and benefits though. I do think that a decimal type should be standard along side a float so that the most appropriate one can be chosen.
by beached_whale 10y ago
It's all about costs and benefits though. I do think that a decimal type should be standard along side a float so that the most appropriate one can be chosen. But in many contexts, one needs to go outside the immediate ecosystem to third party libraries to get an alternative to floating point. Currency is a good example of a type that should not use floating point arithmetic but is far too often.
- Gibbon1 10y agoI think the difference is binary floating point tends to be on massive automatically generated sets of data. And binary floats are mostly perfect for that. However the bias towards scientific computing is a problem. because there are large numbers of use cases where the inputs and outputs are decimal floats because you're dealing with humans and their preference for base 10.