class Node(object):

    def __init__(self, value, left=None, right=None):
        self.value, self.left, self.right = value, left, right
x = Node(3)
x.left = Node(2)
x.left.left = Node(1)
x.left.left.left = Node(1)
x.left.left.right = Node(0)
x.left.right = Node(1)
x.right = Node(1)
x.right.left = Node(1)
x.right.right = Node(0)
in_order(x)
list(in_order(x))
Python in order traversal to a flat list