![]() |
|
Just another Perl shrine | |
PerlMonks |
Re: decimal precisionby why_bird (Pilgrim) |
on May 30, 2008 at 15:08 UTC ( #689243=note: print w/replies, xml ) | Need Help?? |
and than deal with that number when calculating the next number in the iteration (last number in the list) This suggests to me that you actually want to use the rounded number in the next line of your iteration. Is this intentional? A method that doesn't rely on interpreting the number in string context is as follows: prints:
This obviously introduces rounding errors. is that what you want or have I mis-interpreted the question? Those are my principles. If you don't like them I have others. -- Groucho Marx .......
In Section
Seekers of Perl Wisdom
|
|