Come for the quick hacks, stay for the epiphanies. | |
PerlMonks |
Re: Best way to round a number.by ww (Archbishop) |
on Oct 25, 2012 at 01:41 UTC ( [id://1000745]=note: print w/replies, xml ) | Need Help?? |
Actually, the "best" way to round a number may be as follows:
There appears to be some general agreement that any multiple of ten is a "round" number. If that's not a broad enough concensus, try concatenating 2, 3, 4 or 5 zeros. This solution is scarcely more fatuous than your suggestion that the best way to round a number is "the logic on the sample code...."
In Section
Seekers of Perl Wisdom
|
|