##
# example 2
my @ary = qw(
Foo and Bar
went up the Baz
to fetch a Gom Jabar
);
printref(\@ary,(0,2,6,10,11));
sub printref {
my $ary = shift;
print "$$ary[$_]\n" for @_;
}
##
##
# example 3
my @ary = qw(
Foo and Bar
went up the Baz
to fetch a Gom Jabar
);
printref(\@ary[0,2,6,10,11]);
sub printref {
my $ary = shift;
print "$_\n" for @$ary;
}