in reply to Passing multiple data types to a subroutine

First off, everything you pass to a sub gets flattened to a list. Scalars, Arrays, Hashes, all turn in to a list. Which means that it's impossible to tell two arrays apart. Now for simple cases, where you just trying to pass one Array or Hash, you can just put the scalars first and shift them off:
foo($bar,$baz,@qux); sub foo { my $bar = shift; my $baz = shift; my @qux = @_; # or my($bar,$baz,@qux)=@_; }
But if you want to pass two distinct arrays and/or hashes, you have to resort to referenecs.
foo(\@arr1,\@arr2); sub foo { my @arr1=@{+shift}; my @arr2=@{+shift}; }