摘要:
尤其注意:append,+,extend的区别 Method/Function Description Example Input Resulting List/Output append(x) Adds a single element x to the end of the list. [1, 阅读全文
摘要:
The Tree class is defined as below. class Tree: """ >>> t = Tree(3, [Tree(2, [Tree(5)]), Tree(4)]) >>> t.label 3 >>> t.branches[0].label 2 >>> t.branc 阅读全文
摘要:
the provided structure of link class Link: """A linked list. >>> s = Link(1) >>> s.first 1 >>> s.rest is Link.empty True >>> s = Link(2, Link(3, Link( 阅读全文