Demo Trees in Lean
Tracks
Check a result Declarations Bibliography Lean source

Checking a result

Lean checks every proof. What a person must check is that the statements say what the text claims. Select a result to see which definitions it rests on.

  • Chapter 1 · 2 definitions in 1 chapter
    Statement

    A tree is either empty or a node with two subtrees. Its size is the number of nodes, so the empty tree has size 00.

  • Chapter 2 · Sleator and Tarjan 1985 · 3 definitions in 2 chapters
    Statement

    For every tree tt, the cost of an access is at least the number of nodes of tt:

    size(t)≤cost(t).\mathrm{size}(t) \le \mathrm{cost}(t).
  • Chapter 3 · 4 definitions in 1 chapter
    Statement

    If every number in a list is at most bb, the total weight of the list is at most bb times its length.

Select one or more results above to see what to read.