binmode(YP, ":utf8");
binmode(WP, ":utf8");
-match: while(<YP>) {
+match: while(<WP>) {
chomp;
for $prev (@matches) {
next match if (lc $prev) eq (lc $_);
flush;
push @matches, $_;
}
-match: while(<WP>) {
+match: while(<YP>) {
chomp;
for $prev (@matches) {
next match if (lc $prev) eq (lc $_);