sub util_remove_duplicates { my %hash; undef %hash; @hash{ref $_[0] eq 'ARRAY' ? @{$_[0]} : @_} = (); return keys %hash; }