11 lines
249 B
Perl
11 lines
249 B
Perl
|
#!/bin/perl
|
||
|
my $arrays = [ '1', '2', '3', [ 'red', 'blue', 'green' ]];
|
||
|
for($i=0;$i<3;$i++){
|
||
|
print $arrays->[$i],"\n";
|
||
|
}
|
||
|
|
||
|
for($i=0;$i<3;$i++){
|
||
|
print $arrays->[3]->[$i],"\n";
|
||
|
}
|
||
|
print "@{$arrays}\n";
|
||
|
print "--@{$arrays->[3]}--", "\n";
|