Wrong answer for IALG2 UNKNOWN DIRECTORY

problem link : [link][1]
submission link :


[2]

I am adding words to the trie and while adding i also store at each node the lexicographically largest encrypted code encountered till now in it. As the encrypted code is unique for all the strings I maintain a hashmap with key=encrypted string and value = original string Then for any query my answer is simply the number of vowels in the original string found after searching the prefix in trie. Why is my code giving wrong answer. Can someone provide some test cases where this fails??


  [1]: https://www.codechef.com/problems/IALG2
  [2]: https://www.codechef.com/viewsolution/22618092
//