for my $n ($[..$#a) { ... }
For the rare possibility where the first index of arrays may be non-zero as a result of some other strange code obfuscation. :-)
Update : push(@b, sprintf("%.2f", $_)) foreach @a; as suggested by larsen may be nicer and much prettier, but hey! I like obfuscated code :-)
Ooohhh, Rob no beer function well without!
In reply to Re: Re: Re: sprintf and for loop weirds???
by rob_au
in thread sprintf and for loop weirds???
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |