Skip to content

Glossary: Coding Interviews in JavaScript

Tree recursion

Pattern 6: return a base answer for an empty tree, ask each child for its answer, then combine them with the node's value. It costs O(n).

Where the book teaches it

Related terms

PatternBase case