December 2022
Intermediate to advanced
528 pages
15h 41m
English
The contents of a file system can be represented as a tree: The children of a directory are its files and subdirectories. In contrast to the binary search trees of Chapter 8, nodes in a file system can have more than two children, making the tree N-ary. A navigable file system extends a file system by maintaining a current position that can be moved up and down the tree. It is implemented functionally as a zipper. Trees form a recursive data structure in which a node contains a list of trees. Recursion is combined with higher-order list methods to build and traverse trees and zippers.
Our previous case study discussed a possible implementation of binary search trees, in which ...
Read now
Unlock full access