Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Re^2: Determine steps between two numbersby grizzley (Chaplain) |
on Sep 05, 2012 at 13:32 UTC ( [id://991852]=note: print w/replies, xml ) | Need Help?? |
IMHO in such case the variable name should be changed from 'increment' to 'decrement'. Or better - change algorithm to more intuitive:
And one-line @array generator as alternative: my @array = map { $first + $increment * $_ } 0 .. $steps - 1;
In Section
Cool Uses for Perl
|
|