is a comprehensive book on getting a job at a top tech company, while focuses on dev interviews and does this for PMs.
CareerCup's interview videos give you a real-life look at technical interviews. In these unscripted videos, watch how other candidates handle tough questions and how the interviewer thinks about their performance.
Most engineers make critical mistakes on their resumes -- we can fix your resume with our custom resume review service. And, we use fellow engineers as our resume reviewers, so you can be sure that we "get" what you're saying.
Our Mock Interviews will be conducted "in character" just like a real interview, and can focus on whatever topics you want. All our interviewers have worked for Microsoft, Google or Amazon, you know you'll get a true-to-life experience.
a. Create a min-heap of intervals based on opening values. O(n)
- kishoreblack May 06, 2014b. Retrieve the min element from the set of intervals in O(1). It will be the first element from the min interval of the heap.
c. Check for heap property and sink the interval down if needed in O(log n) time.
d. Repeat steps b and c for i number of times. The element retrieved in ith iteration is the required ith smallest element.
Time complexity - O(i * log n) [i>>>n], space complexity - O(n)