# Who Works Under Whom? Trees

List everyone who works under a manager in a company of 10,000, without rereading every row for every person: why a list of rows and a name-to-manager dictionary fall short, and the structure that fixes them, the tree, with its words (root, parent, child, leaf, depth and height).

![Cheat sheet: Who Works Under Whom? Trees](https://fsdtrainingmedia.blob.core.windows.net/public/images/2026/11/ec41a22e89da48d6bacb50c429d8251c.webp)

- Category: Data Structures
- Level: Apprentice
- Tags: data structures, Leaf Node, Node Depth, Root Node, Subtree, Tree, Tree Height
- Updated: November 3, 2026

Source: https://www.ask-codey.com/cheat-sheets/ds-trees-cheat-sheet
