sub clean_hash { while ( ( my $key, my $value ) = each %hash ) { delete $hash{$key}; } }