Pergunta de entrevista da empresa Google

Given a dictionary of words, write a function that would autocomplete word prefixes.