$scalar = 'blue'; %hash = ('a' => 1, 'b' => 2); myfunc($scalar, %hash); sub myfunc { my $scalar = shift; my %hash = @_; print $hash{'a'}; }