input: Write a python function to create a tree and print it using pre-order traversal.
  assert traverse(Tree('A')) == ['A']
  assert traverse(Tree('A', [Tree('B'), Tree('C')])) == ['A', 'B', 'C']
  assert traverse(Tree('A', [Tree('B', [Tree('D'), Tree('E')]), Tree('C')])) == ['A', 'B', 'D', 'E', 'C']
output: class Tree:
      def __init__(self, value, children=None):
          self.value = value
          self.children = children if children is not None else []
  
  def traverse(node):
      result = []
  
      def pre_order(node):
          if node is None:
              return
          result.append(node.value)
          for child in node.children:
              pre_order(child)
      
      pre_order(node)
      return result