code: def pretty_print_str(self):
          '''
          Create a string to pretty-print this trie to standard output.
          '''
          retval = ''
          # dfs
          todo = [self.root]
          while todo:
              current = todo.pop()
              for char in reversed(sorted(current.keys())):
                  todo.append(current[char])
              indent = ' ' * (current.depth * 2)
              retval += indent + current.__unicode__() + '\n'
          return retval.rstrip('\n'f pretty_print_str(self):
          '''
          Create a string to pretty-print this trie to standard output.
          '''
          retval = ''
          # dfs
          todo = [self.root]
          while todo:
              current = todo.pop()
              for char in reversed(sorted(current.keys())):
                  todo.append(current[char])
              indent = ' ' * (current.depth * 2)
              retval += indent + current.__unicode__() + '\n'
          return retval.rstrip('\n')
docs: Create a string to pretty-print this trie to standard output.