LinkedIn SSE | Systems and Infra | Rejected

Difficulty: MEDIUMCategory: InterviewExperienceFrequency: 1Asked On 2025-03-17Added By Anonymous
Source: Link

Hackerrank OA:


1.a perfect pair (x, y) is such that
2.min( | x - y |, | x + y | ) <= min( | x |, | y |) && max( | x - y |, | x + y | ) >= max( | x |, | y |)
3.given an array of unsorted integers, find the number of perfect pairs
4.example [2, -3, 5]
5.(2, -3) and (-3, 5) are perfect pairs


1.https://leetcode.com/problems/longest-string-chain/description/


Cleared all the Test Cases.

Result: Positive

Phone Screen:

(Rescheduled this round thrice. Twice by the recruiter. And once by me)

1.Brief walkthrough about your projects mentioned in your Resume.
2.OS(Paging, stacks and heaps, paging) concepts, Networking concepts(TCP vs UDP), DBMS Concepts(ACID Properties).
3.I did not answer properly about the Durability in ACID. I don't know I just didn't remember much about it during the interview.


Coding problem:

I wasn't given a LC problem I guess.


1abstact class NestedInteger { 2 public: 3 virtual bool isInteger() const = 0; 4 virtual int getInteger() const = 0; 5 virtual const vector<NestedInteger> &getList() const = 0; 6}; 7/ * 8* nums: {1, {4, {6, 4}}} 9* this would look like 10* 1 depth 3 => 1 * 3 = 3 11* \ 12* 4 depth 2 => 2 * 4 = 8 13* \ 14* 6, 4 depth 1 => 6*1 + 4*1 = 10 15* Total sum = 10 + 8 + 3 = 21 16* 17* nums: {{1,1}, 2, {1, 1}} 18* 2 depth 2 => 2 * 2 = 4 19* \ 20* 1, 1, 1, 1 depth 1 => 1*1 + 1*1 + 1*1 + 1*1 = 4 21* Total sum = 4 + 4 = 8 22// Now complete the below function 23int getDepthSum(vector<NestedInteger>& nums) { 24 // Implement here 25}

I solved by doing DFS whenever I a nested list. And saved my result in a new vector. for example 1, my new vector will be [[1], [4], [6,4]] and then I will traverse and calculate the sum. Interviewer was OK with this approach. Dry ran it. Worked.

Follow up: To do it without extra space. They wanted to me calculate sum at each level and complete the sum at each level with the help of current depth and max_depth as I was doing a DFS. Discussed only the approach. Did not dry run it. I had some questions around it and we ran out of time


Verdict: Rejected


Feedback: I didn't answer about Atomicity. And I used extra space for the vector. Got it directly from the recruiter. "You solved the problem but for an SSE, you gotta solve it without extra space"

I guess I should practice more DFS. Please let me know the topics I should cover to deal with problems like this.


Timeline: 2 weeks with all the rescheduling considered.

Guys please grind hard. Peace ✌️.

Comments