use strict; use warnings; use Data::Dump::Streamer; my $location_hash = { 'New York' => {ZIP => '123-456-789'}, 'Dunedin' => {ZIP => '9001'} }; for my $city ( keys %$location_hash ) { print "$city $location_hash->{ $city }->{ZIP}\n"; delete ($location_hash->{ $city }); delete ($location_hash->{ $city }->{ 'ZIP' } ); } Dump $location_hash; #### Dunedin 9001 New York 123-456-789 $HASH1 = { Dunedin => {}, "New York" => {} };