Help for this page

Select Code to Download


  1. or download this
    # Passing array refs from function returns...
    foo([split(',', $a)], [split('/', $b)]);
    ...
    # Passing hard coded data (used in CGI etc.)
    bar([1..4],
        { 1 => "foo", 2 => "bar", 3 => "abcd", 4 => "xyz"});
    
  2. or download this
    # "anonymous" reference to array of 8
    my $foo = [1..8];
    ...
      # Create reference to array of 8
      $foo = \@foo;
    }