Pregunta de entrevista de Gradifi

Write code for the missing part of this commented code. It doesn't need to compile or run. (Anagrams)