LinkedIn Phone screen and Onsite | Senior Software Engineer

Difficulty: MEDIUMCategory: InterviewExperienceFrequency: 1Asked On 2024-04-16Added By Anonymous
Source: Link

Phone Interview:

1.Search number in rotated array. -> 1st question
2.Find the diameter of a binary tree -> 2nd question


Onsite interview


•Find the inclusive and exclusive times of a function -> a tweaked version of https://leetcode.com/problems/exclusive-time-of-functions/description/
•Find the lowest common ancestor of binary search tree
•Find the lowest common ancestor of binary tree


•Design a data structure that supports adding new words and finding if a string matches any previously added string.
•

Implement the WordDictionary class:

1WordDictionary() Initializes the object. 2void addWord(word) Adds word to the data structure, it can be matched later. 3bool search(word) Returns true if there is any string in the data structure that matches word or false otherwise. word may contain dots '.' where dots can be matched with any letter.

3. Design typeahead search in linkedin. If you type a prefix in search box, it should populate the people with that prefix in your connections, connections of connections, and companies.

Comments