in reply to Re: Re: Re: Using (s)printf()
in thread Using (s)printf()
Actually, this isn't quite the whole story. Most everyone follows the IEEE convention of "round towards nearest or even."I'm aware of that - but it wasn't applicable in this case. Btw, (s)printf doesn't seem to get it right:
and 0.5 can be represented exactly ...printf "%.15f", 0.5; # prints 0.500000000000000 printf "%.0f", 0.5; # prints 1 and should print 0
-- Hofmator
|
---|
In Section
Tutorials