sub some_function { my $arg1 = shift; # shift the first value off of @_ my ($arg2, $arg3, ) = @_; # or copy all of @_ at once # process stuff return $some_value; } # called like this $value = some_function( 1, 2, 3 );