3 ms·
Few applications need them for correctness according to domain requirements. Compare with fixed-precision decimal encodings, which are mathematically less fund
by dkarl 5y ago
Few applications need them for correctness according to domain requirements. Compare with fixed-precision decimal encodings, which are mathematically less fundamental, but are common in programming because many applications require monetary amounts to be calculated using fixed-precision arithmetic.
It's true that floating point calculations are much faster, but we do a lot of expensive things in code when we need to, and people do use rational types when they need exact rational arithmetic. It just doesn't happen very often.