My Perl Quiz

The ultimate place to learn Perl!

Question #32: What will be the value of $count after executing the following code?

my %hash = (a => 1, b => 2);

my $count = 0;

while (my ($key, $value) = each(%hash)) {
    $count++ if $value == keys(%hash)
}