What is the left-child, right-sibling representation of a tree? Why would you use it?

The left-child, right-sibling representation (LCRS) is a way of encoding a multi-way tree (a tree structure in which each node can have any number of children) using a binary tree (a tree structure in which each node can have at most two children). Motivation To motivate how this representation works, let’s begin by considering a … Read more