my ($marker, @pairs) = split; my $c = 0; while (@pairs) { ++$c; my ($thing1, $thing2) = splice(@pairs, 0, 2); print "$marker $c $thing1 $thing2\n"; }
In reply to Re^3: Perl Regex
by Roy Johnson
in thread Perl Regex
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |