Problem 2583 · Medium

Kth Largest Sum in a Binary Tree

Sum each level of a binary tree and keep the k largest level sums in a bounded min-heap.

Open the interactive visualisation