A
Alythh
hi people,
I've some troubles trying to access an array of arrays:
while using the format:
for $i ( 0 .. $#AoA ) {
$row = $AoA[$i];
for $j ( 0 .. $#{$row} ) {
print "element $i $j is $row->[$j]\n";
}
}
surely works, I was wandering if there is a way to scan @AoA for its
$i-th row, and returning it as @i_row, without rebuilding it (by
pushing one-by-one $row->[$j], as in previous example):
it is both an efficiency worry, and a styilistic one: that code is
awful!
Thanks for your help
Alessandro Magni
I've some troubles trying to access an array of arrays:
while using the format:
for $i ( 0 .. $#AoA ) {
$row = $AoA[$i];
for $j ( 0 .. $#{$row} ) {
print "element $i $j is $row->[$j]\n";
}
}
surely works, I was wandering if there is a way to scan @AoA for its
$i-th row, and returning it as @i_row, without rebuilding it (by
pushing one-by-one $row->[$j], as in previous example):
it is both an efficiency worry, and a styilistic one: that code is
awful!
Thanks for your help
Alessandro Magni