in reply to 'each' syntax oddity?
for (my $i = 0; $i < $#array; $i+=2) { my ($first, $second) = @array[$i, $i+1]; # Do stuff here ... }
------
We are the carpenters and bricklayers of the Information Age.
Don't go borrowing trouble. For programmers, this means Worry only about what you need to implement.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
•Re: Why do Perlers hate C-style for-loops, especially when they're called for?
by merlyn (Sage) on Mar 07, 2002 at 15:03 UTC |