No test case being passed

@sufia.aleena12, according to the question you have to insert the word in the trie if the word is not found so handle that case and also in your print function p = w + it->first; you should not do this as for every loop it will add a new character in p , instead add the character in p inside the function .
refer this code , i have commented each logic:-