Position: L3
[Q1] How do you find smallest non-negative integer that doesn't exist in the given array (including zero)
*array can have duplicates
followup:
Answer:
[Q2] What's the slowest program you can write with n bits?
Answer:
afterthought:
The answer for Q1 the interviewer gave me before he moves to the second question. I got the second answer for Q2 after the interview ends and couldn't really explain well during the interview. I just finished the interview and don't think I pass it but hope this helps someone. I will keep trying. This was my 4th try for Google.
I should've done more hard question and practice outloud under the time pressure.