my @array = qw(1 1 0 2 0 1 3 0 0 4 1 1); my $i = 1; for (@array) { print; print $i++ % 3 ? "," : "\n" } print "\n";
In reply to Re: Group array in threes
by repellent
in thread Group array in threes
by joec_
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |