def Inorder_traversal(self):

if self is None:

return []

return (TreeNode.Inorder_traversal(self.left)

+ [self.key]

+ TreeNode.Inorder_traversal(self.right))

```
def Preorder_traversal(self):
if self is None:
return []
return ([self.key]
+ TreeNode.Preorder_traversal(self.left)
+ TreeNode.Preorder_traversal(self.right))
def Postorder_traversal(self):
if self is None:
return []
return (TreeNode.Postorder_traversal(self.left)
+ TreeNode.Postorder_traversal(self.right)
+ [self.key])
```