Problem 222 · Easy

Count Complete Tree Nodes

Count the nodes of a complete binary tree in O(log^2 n) by comparing spine heights.

Open the interactive visualisation