Leser: 15
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
#!/usr/bin/perl use strict; use warnings; sub something { print "\'$0\' blabla \'$1\' blablabla \'$2\'\n"; } my @list; my $BUU="buu"; my $DIE="da"; push @list, [ "foo", "faa", "fee" ]; push @list, [ "boo", "bii", $BUU ]; push @list, [ "dee", "daa", $DIE ]; &something( @list->[0] );
&something( @list->[0] );
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
#!/usr/bin/perl use strict; use warnings; sub something { my ($arrayref) = @_; print $_,"\n" for @{$arrayref}; } my @list; my $BUU="buu"; my $DIE="da"; push @list, [ "foo", "faa", "fee" ]; push @list, [ "boo", "bii", $BUU ]; push @list, [ "dee", "daa", $DIE ]; something( $list[0] );