harbor run -t openthoughts/tasktrove-exp-rpt-taco-v2-taco-0599harbor download openthoughts/tasktrove-exp-rpt-taco-v2-taco-0599Polycarpus participates in the "Field of Wonders" TV show, where contestants guess a hidden word by revealing letters one at a time. Initially, all the letters of the word are hidden.
At each turn, the participant guesses a letter, and if that letter exists in the hidden word, the host reveals all instances of it. For example, if the hidden word is "abacaba" and the guess is "a", the host reveals the letters at positions 1, 3, 5, and 7.
Polycarpus knows m words of the same length as the hidden word, which includes the hidden word itself. At present, some letters of the hidden word may already be revealed, and thus Polycarpus wants to guess a letter that will definitely reveal at least one more letter.
Your task is to help Polycarpus count how many letters he can confidently guess so that the host will reveal at least one undisclosed letter.
n (1 ≤ n ≤ 50) — the length of the hidden word.n representing the already revealed letters. The string consists of lowercase Latin letters and symbols "". A letter indicates it has been revealed, and "" indicates that the letter is still hidden. At least one letter is still hidden.m (1 ≤ m ≤ 1000) — the number of n-length words known to Polycarpus.m lines each contain a distinct n-letter string composed of lowercase Latin letters.It is guaranteed that the hidden word appears among the m words, and that Polycarpus has previously guessed the letters that are currently revealed.
Output a single integer representing the number of letters that Polycarpus can guess that will definitely reveal at least one more letter. It is possible that this number can be zero.
4
a**d
2
abcd
acbd
2
5
lo*er
2
lover
loser
0
3
a*a
2
aaa
aba
1
Your implementation should be placed in the /app/ directory.
Important: place your implementation at /app/solution.py so the verifier can run it.