![]() |
|
P is for Practical | |
PerlMonks |
Re: ceil without ceilby why_bird (Pilgrim) |
on Mar 13, 2008 at 14:48 UTC ( #673983=note: print w/replies, xml ) | Need Help?? |
I think this would be better:
The code above rounds any number smaller than 9e-9 incorrectly to 0. For a lot of applications I suppose this won't make a difference, but why write a mathematical function that is not correct? It might be copied by someone else who assumes that it will work correctly in every circumstance*. *Yes it would be a stupid assumption to make, but you can never tell.. waits for someone to point out the error in her method why_bird Those are my principles. If you don't like them I have others. -- Groucho Marx .......
In Section
Meditations
|
|