I'd disagree that there is any problem with sprintf and 'rounding'.

Basically, you can round towards zero, away from zero, or use unbiased
rounding. Towards even is the accepted method of unbiased rounding.
Unbiased rounding is the method least likely to introduce bias into your
end results.

If you are using floating point arithmetic, you want unbiased rounding,
'even' if you don't realise that this is good for you.

It is always possible to make floating point operations look odd by
throwing specific literals into the mix.

Many folks seem to use floating point numbers, when what they want are
numbers of a specific precision and scale.

Regards

Mark


_______________________________________________
Perl-Win32-Users mailing list
Perl-Win32-Users@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Reply via email to