All Questions
1
question
1
vote
1
answer
103
views
correcting an invalid binary heap in $\Theta (n)$
We are given a binary max (every node is larger than its children) heap with $n$ elements.
We now change $\frac{n}{4}$ of the elements at random. We don't know which ones and to which value. And so, ...