Here is the another way
@arr = qw (1 1 0 2 0 1 3 0 0 4 1 1); for (0..@arr/3) { print $arr[3*$_],$arr[3*$_+1],$arr[3*$_ +2],"\n"; }
In reply to Re: Group array in threes
by lakshmananindia
in thread Group array in threes
by joec_
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |