[ INFO ]category: Behavioral · Phone Screen difficulty: medium freq: first seen: 2024-04-04
[MEDIUM][PHONE SCREEN]Phone ScreenE5Unknown
$catproblem.md
I was asked two fairly straightforward questions.
Given a long list/array of 1s and 0s and two indices i and j, return the number of 1s between those two indices in O(1) time.
The interviewer was looking for pre-processing using a hashmap and cumulative sum, which I coded up.
Merge 3 sorted arrays, while removing any duplicates in the final sorted array.
I took a couple of hints for this, but I eventually got to the solution in time. I took the global minimum over three pointers and moved each one depending on the choices. One concern I had was that I might have missed a boundary check in the code, and I did tell the interviewer this and would test more aggressively if I had a few more minutes.
I think I did okay overall, but no feedback yet. My chances depend on how lenient they are with the hints and the out-of-bounds check in the second problem. I am leaning towards a rejection but will update when I know.