def main(argv):
    try:
        opts, args = getopt.getopt(argv, "", ["word="])
        result = dictionary.find_largest_anagram(args.pop())
        print result
        print dictionary.getDefnition(result.pop())
    except getopt.GetoptError:
        print 'countdown_solver.py <letters>'
        sys.exit(2)
Ejemplo n.º 2
0
def solver(word):
    resultset = dictionary.find_largest_anagram(word)
    results = list(resultset)

    return jsonify(anagrams= results)