- trees where nodes have a **max of two children**
- **left** and **right** child
- among the most common algorithm problems
![[CleanShot 2024-05-19 at
[email protected]]]
- real life implementations: (think they mean general trees)
- file systems
- comment threads on Reddit & Twitter
```
class TreeNode:
def __init__(self, val, left, right):
self.val = val
self.left = left
self.right = right
```
- complete binary trees are where at every level (except possibly the last level), the entire row is filled
![[Complete_binary2.svg.png|300]]