From: Joe Van Dyk Date: 2005-12-13T14:09:39+09:00 Subject: Re: Using Float For Currency On 12/12/05, mental@rydia.net wrote: > Quoting Hunter's Lists : > > > Howdy, > > > > I have some methods that manipulate floats that represent a > > currency amount. > > > > I often end up with more precision than I need, i.e.: $9.756. > > > > What is the best way to scale that to 9.76? > > If you're doing anything that matters, don't use floats for > currency. There are a lot of really nasty subtle issues that will > lose money between the cracks. > > Usually you want a specialized currency type which uses > fixed-precision arithmetic. What cracks can I lose money through?