GOPI Interview Question

Write code for printing anagrams in words ?