TRIE PROBLEM HELP CODECHEF CONTEST UNKNOWN DIRECORY

Правка en1, от aman_naughty, 2019-01-24 23:56:03

problem link : LINK

submission link : code

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??

Теги trie, #data structure, #contest, #strings

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en3 Английский aman_naughty 2019-01-25 16:48:32 39 Tiny change: ' fails??\n' -> ' fails??\n\nP.S. why are people downvoting this\n'
en2 Английский aman_naughty 2019-01-25 16:47:57 48 Tiny change: '\nproblem li' -> 'problem li'
en1 Английский aman_naughty 2019-01-24 23:56:03 685 Initial revision (published)