2 ms·
I'd love to see a language or even a library that would make no-surprise fixed point and/or arbitrary precision math first class citizens, like what Python did
by zokier 14y ago
I'd love to see a language or even a library that would make no-surprise fixed point and/or arbitrary precision math first class citizens, like what Python did with integers.
- dlitz 14y agoPython has a decimal (as opposed to binary) floating-point library, which is great for doing math with inherently decimal quantities (e.g. money): http://docs.python.org/3.3/library/decimal.html http://docs.python.org/3.3/library/decimal.html
- whattssonn 14y agoCOBOL and RPG, for example, on Mainframe / Midrange systems have native support for fixed point (decimal) types. It's the second most used type, besides the "character" types. Floats are seldom used in the context of business applications. Fixed point math is even directly implemented in hardware on Power processors. Always been like that on IBM platforms.