3 ms·
Binary Coded Decimal is something else. 1100 in “regular” binary is 12 in decimal. 0001 0010 in BCD is 12 in decimal. ie: bcd is an encoding. High precision
by imoverclocked 1y ago
Binary Coded Decimal is something else.
1100 in “regular” binary is 12 in decimal.
0001 0010 in BCD is 12 in decimal.
ie: bcd is an encoding.
High precision numbers are more akin to the decimal data type in SQL or maybe bignum in some popular languages. It is different from (say) float in that you are not losing information in the least significant digits.
You could represent high precision numbers in BCD or regular binary… or little endian binary… or trinary, I suppose.
- froh 1y agoyes and... bcd arithmetics are directly supported on CPUs for financial applications, like Z: IBM z Systems Processor Optimization Primer https://share.google/0b98AwOZxPvDO6k15 https://share.google/0b98AwOZxPvDO6k15