my @array_child = qw(1 2 3 4); my @array_parent = qw(5 6 7 8); my ($child_ref,$parent_ref) = methode(\@array_child,\@array_parent); sub methode{ my ($ref_child,$ref_parent) = @_; my @child = @$ref_child; my @parent = @$parent; # mach was return \@child,\@parent; }