how to write a program of anagram in python