in reply to Re (tilly) 1: strange rounding behaviour
in thread strange rounding behaviour

Nice catch tilly. I missed that case.

My opinion boils down to this: use string formatting routines for formatting strings (not rounding numbers), and use numeric tools for numeric operations (like rounding). Using a string operator (like sprintf) to do a numeric function (rounding) is just asking for "unexpected complications".

  • Comment on Re: Re (tilly) 1: strange rounding behaviour