Overall the interview wasn't hard. It had three parts: BQ, coding, and a small system design.
BQ had two questions:
"Tell me about a time when you saved a failure from your work"
"Tell me about a time where you are blocker"
I used two examples of cross-org collaboration to show scalability and impact.
Coding
Given a k-dimensional array and the size of each dimension (dimensions), you can only access elements through array.get(indices). Compute the sum of all elements in the whole array.
The idea is pretty clear. Since the number of dimensions k isn't fixed, you can't hard-code nested for loops, so I used DFS to simulate the nested loops dynamically. dfs(d) picks the index for dimension d, and current_indices keeps the full coordinate so far. When d == len(dimensions), all dimensions have been chosen, so you call array.get(current_indices) and add it to the total.
For example:
function sumKDArray(array, dimensions):
indices = [0] * number_of_dimensions
return dfs(0)
function dfs(d):
if d == number_of_dimensions:
return array.get(indices)
total = 0
for i from 0 to dimensions[d] - 1:
indices[d] = i
total += dfs(d + 1)
return total
System Design
Design a search ranker. You need to cover feature input, ranker design, training, hosting, and eval.
Overall I thought the interviewer was really nice and very engaging. Just treat them like a coworker and chat with them.
Discussion
Loading comments…