Google interview question

A leecode medium question about heap

Interview Answer

Anonymous

7 Mar 2026

i use brute force to start, and come with a follow up question, use min-heap to solve question, To prove my steps, i show the interview a math