Re: sorry .09 instead of .08



zero wrote:

So, don't use doubles for financial calculations.

that's really the bottom line isn't it :-) Use whatever works for you, as long as it isn't double (or worse, float).

I'd strongly disagree. The problem is failure to understand roundoff, not any particular number representation. You'll eventually get bitten if you decide that avoiding floating-point primitives is all you need to do. Conversely, if you want to do anything more than adding and subtracting, you'll find the floating-point primitives very hard to avoid.

- Ernie                                  http://home.comcast.net/~erniew

.