Binary heap tree proof: index of left child is doubled index of parent + 1
We can often see, that i_left_child = i_parent * 2 + 1. And even though this formula is easy to check, it’s quite hard to believe in it, without a formal proof. I made an image that proofs this quite commonly used in computer science fact.
Continue…