METAL XXX <metal...@gmail.com> added the comment: Sorry I ripped the code from a mess and I forget the tree is "leaflized" as
tree = { 'A': set(['B', 'C', 'D', 'E']), 'B': set(['D', 'E']), 'C': set(), 'D': set(), 'E': set(), } I don't want to talk about the actual problem. I think sometime it's hard to give an "absolute" weight value as key, for this example, is the relationship in graph. Then user have to "Copy and paste the recipe" to get a cmp function which should be already there. We are all adults here, why don't SIMPLELY tell the newbie don't use cmp() use key() unless you know what you are doing. Thanks for reply. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue1771> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com