I was contacted by a recruiter from LinkedIn in early December 2020 to apply for software internship role. So I filled the application form provided.
The process consisted of 1 online assessment and 2 interviews.
Date : 14 Dec 2020
Platform : HackerRank
Time : 90 minutes
Number of questions : 4
Find the 4th least significant digit of a number.
Solution Approach : https://www.geeksforgeeks.org/print-kth-least-significant-bit-number/
Given an array of numbers, find the number of unique pairs with sum equal to a target value.
Solution Approach : https://www.geeksforgeeks.org/count-distinct-pairs-with-given-sum/
Given an array of capacities of umbrellas, find the minimum number of umbrellas to cover exactly n people.
Solution Approach : https://www.geeksforgeeks.org/find-minimum-number-of-coins-that-make-a-change/
Given a weighted graph, output for each edge if it lies on any shortest path between node 1 and node N.
Solution Approach :
- Find the lengths of shortest paths from all nodes to node 1. Store them in array A.
- Find the lengths of shortest paths from all nodes to node N, Store them in array B.
- Let the shortest path distance between node 1 and N be minD.
- Take a boolean array E corresponding to edges of the given graph, initialize it with all FALSE values.
- For each edge i-j (corresponding to index k of array E) do :
- If A[i] + weight of edge i-j + B[j] = minD OR A[j] + weight of edge i-j + B[i] = minD then mark E[k]=TRUE.
- Output array E.
I completed all the questions in 75 minutes with all testcases passed.
Interview 1 (DSA Round)
Date : 21 Dec 2020
Platform : Video call through Zoom, live coding on https://coderpad.io/
Duration : 1 hour
The interviewer firstly introduced himself and gave an overview of the work done under his team. The work related to login authentication grabbed my interest and I asked some questions on the same. After this, I was asked to introduce myself. He asked a few questions about one of the hackathons I participated in.
This took around 15 minutes.
Then I was asked to write the codes and time & space complexities for the following questions one-by-one. The interviewer explained some examples for each question and we performed dry run over some testcases after I wrote the codes.
Intersection of Arrays
- Given two arrays, find the elements occurring in both of them. (Here, it is important to ask the interviewer how we are expected to handle duplicate elements)
- Provide an optimized solution if the arrays are already sorted.
- Give an optimized solution if one array is very large as compared to the other. (I used binary search on larger array, making suitable modifications to handle repeated elements)
Input : [1, 3, 3, 5] , [1, 3, 3, 3, 5, 5, 7, 8]
Output : [1, 3, 3, 5]
Similar article : https://www.geeksforgeeks.org/union-and-intersection-of-two-sorted-arrays-2/
Number of connected components
Given a matrix of alphabets, find the number of connected components, considering all 8 neighbors.
Output : 4
Similar article : https://www.geeksforgeeks.org/connected-components-in-an-undirected-graph/
The whole coding part got completed quickly and easily.
There were still almost 10 minutes left, so we discussed about life at LinkedIn and I told him about some of the features of the LinkedIn app that I thought should be improved.
Interview 2 (Host-Manager Round)
Date : 8 Jan 2021
Platform : Video call through Zoom
Duration : 1 hour
This was a behavioral interview. Starting with the introductions of both of us, we discussed about the fake-content checking(one of the tasks being done by his team at LinkedIn).
Then I was asked to describe one the projects that I had mentioned on my resume.
After this, some behavioral questions were asked, like :-
- What are your expectations from the internship?
- Tell me about a situation
- when you faced conflict of ideas with your teammates.
- when your idea got discarded and you had to follow the rest of the team.
- when the outcomes of a project were not as expected.
- when you managed to bring results even after facing a lack of resources.
- when you felt that you lack certain skills.
- What kind of work would you like to do during your internship?
This whole interaction was quite interesting for me and I really got to analyze a lot of my own experiences from various contests and events.
At last he asked me if I had any questions for him and after my questions the interview ended.
After 2 days I received a call from the recruiter about my selection for the internship.
Most helpful resources based on my experience : GeeksForGeeks, InterviewBit, CodeForces.
Whether you're preparing for your first job interview or aiming to upskill in this ever-evolving tech landscape, GeeksforGeeks Courses
are your key to success. We provide top-quality content at affordable prices, all geared towards accelerating your growth in a time-bound manner. Join the millions we've already empowered, and we're here to do the same for you. Don't miss out - check it out now!