my %x; print "one\n" if defined %{$x{a}}; print "two\n" if defined %{$x{a}}; print Dumper( \%x );