Anagram-Hints Continuing...
1. Create a function called Signature(word) that takes a word and returns the anagram-signature for that word. Namely, it will create a list of the characters of the word, then sort that list, and convert that sorted list of characters back into a string. Example: "stop" -> ['s', 't', 'o', 'p'] -> ['o', 'p', 's', 't'] -> "opst"
2. Go through the 80,000 word-list and create a dictionary called dSig that has the word as its key and the word's signature as its value.
3. Invert the dSig dictionary into the dFamily dictionary. This will give you a dictionary that, if you know a signature, will give you the entire family of words that have that signature -- namely the anagram-family. We did invert a dictionary in class on Thursday, but if you've forgotten, I've included a function for doing that in the answers to Friday's in-class exercises here.
4. You can use dSig and dFamily together to answer the questions 1, 2, and 3. And, stepping through the dFamily dictionary, you can solve problem 4.