Pergunta de entrevista da empresa SAP

Program to check the given array has anagrams of the given word or not?