15 Apr
2005
15 Apr
'05
5:37 p.m.
Sliwa, Przemyslaw (London) wrote:
Thanks,
Ben, what should I use for representing the money amounts? A boolean :)) ?
If you're dealing with other people's money then there are regulations that specify the required intermediate precision and rounding rules, which may vary from place to place. I believe you'll need to use fixed-point decimal fractions, perhaps implemented as integer counts of hundredths or ten-thousandths of a currency unit. I've not done this myself so I don't know the details, but I'm fairly sure that getting this wrong can put you on the wrong side of the law. Ben.