[Tutor] data structure question

Tiger12506 keridee at jayco.net
Fri Jan 18 23:04:04 CET 2008


>    def recursive_print(self, level=0):
>        print "\t"*level + self.cargo
>        for x in self.children:
>          recursive_print(x,level+1)

Whoops. should be

for x in self.children:
    x.recursive_print(level+1)


More information about the Tutor mailing list