my %names = ( "sean" => 29, "lisa" => 14, "bob" => 25, "matt" => 23, "tom" => 52 ); my @matches = %names{/a/};