my $threshold = 0.75; my $counter = 0; foreach my $word ( split ' ', $PDBline ) { $counter++ if $XMLline =~ /$word/; }