Software Engineer • Sr.Staff-Level
Software Engineer • Sr.Staff-Level
High QualityPractice Other Questions that LinkedIn Asked
Continue with targeted prep from LinkedIn's coding question bank and system design questions.
Interview Summary
I completed LinkedIn's Senior Staff Software Engineer onsite over two days, consisting of one AI-assisted coding round, two system design rounds, and two behavioral interviews. The coding exercise involved multi-source BFS and calculating emergency response costs, while the design rounds covered PR reviewer assignment and CI job scheduling. I passed the interview process, although some of the system design and behavioral discussions were quite different from what I expected.
Interview Details
Round 1 — AI-Assisted Coding: Fire Station Distance and Response Costs
This coding round allowed me to use an AI assistant that could directly modify my code. I chose GPT 6.1 Sol to help with implementation, so I could discuss approaches with the AI and have it make code changes without manually copying and pasting. I used Go for the implementation.
Part 1 — Find the Nearest Fire Station for Every Residential Cell
The interviewer gave me a two-dimensional grid containing three types of cells:
0: Fire station-1: Residential area-2: Lake or impassable terrain
The grid could contain multiple fire stations. My task was to calculate the shortest distance from each residential cell to its nearest fire station. Fire trucks could move through the grid but could not cross lake cells. The distance was based on grid movement rather than allowing vehicles to pass directly through obstacles. I initially proposed running BFS separately from every fire station and then taking the minimum distance for each residential cell.
The interviewer asked me to analyze the time complexity. I explained that if the number of fire stations was fixed, the complexity would be O(N), where N represented the total number of grid cells. However, if the number of fire stations was also variable, the complexity would become O(M × N), where M was the number of fire stations.
The interviewer did not provide much feedback, so I shared my approach with the AI assistant and asked whether there was a more efficient alternative. The AI suggested multi-source BFS, where all fire stations are inserted into the queue initially with distance zero. This would allow the distances to be computed in O(N) time.
I agreed with that approach and asked the AI to implement it. After the code was generated, I reviewed the implementation line by line before continuing.
Part 2 — Calculate Fire Truck Response Costs
The second part extended the problem by introducing a cost calculation for emergency response. The government would pay for fire truck services according to the distance between a fire station and a residential area.
The pricing system included:
- A base response cost.
- A discount when the distance was 0.
- A different discount when the distance was 1.
- The base cost when the distance was 2.
- A percentage surcharge when the distance was 3.
- Additional distance-dependent adjustments.
- A maximum cost cap.
I needed to calculate the response cost for every residential cell based on the distance to its nearest fire station. I
Unlock Full Details
Create a free account to unlock this interview experience report.