Program to check for anagram