MCPcopy Create free account
hub / github.com/ActiveState/code / getSignature

Function getSignature

recipes/Python/117237_Anagram_Fetcher/recipe-117237.py:5–10  ·  view source on GitHub ↗
( item )

Source from the content-addressed store, hash-verified

3# returns a signature that will be the same
4# for a whole class of anagrams
5def getSignature( item ):
6 item_chars = []
7 for i in range(len(item)):
8 item_chars.append(item[i])
9 item_chars.sort()
10 return string.join(item_chars, "")
11
12# goes through a list of strings and strips
13# away the new lines at the end

Callers 1

recipe-117237.pyFile · 0.85

Calls 4

rangeFunction · 0.85
appendMethod · 0.45
sortMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected