5 ms·
Exactly. (And yes, it's good to point out the right way, not just the wrong way!) I've heard of some applications using tenths of a cent since they needed more
by mikeash 10y ago
Exactly. (And yes, it's good to point out the right way, not just the wrong way!) I've heard of some applications using tenths of a cent since they needed more precision.
For Bitcoin applications, I think you'd want to work in integer satoshis.
- Declanomous 10y agoThe default currency type I've seen used for accounting is a decimal with 4 digits trailing the decimal. I forget the leading digits, but it is something like 14. Basically I think the idea with 4 digits after the decimal is that the smallest denomination you can have is 1 penny, and that allows you to calculate percentages of pennies accurately to a hundredth of a percentage point.
- andrepd 10y agoWhat if you have to calculate, say, a 0.5% fee on a few satoshis?
- AtheistOfFail 10y agoCalculate it and round it off after calculation to the nearest satoshi.