Open In App

# Samsung (SRIB) Internship Interview Experience

There were three rounds in the hiring process.

#### Round 1 (Coding):

It consisted of three programming questions and everyone got different set of questions. Here are the ones that I received:

1. The last non-zero digit of the factorial of a number. To find the factorial for large values of n was costly in terms of time complexity. I optimized the solution and cleared all test cases.
2. Ceil Value Node: Node with smallest data larger than or equal to key value. We were required to find that node in a BST. I went for the the recursive approach and cleared all test cases.
3. Difference between the maximum and minimum depthfrom the root of a binary tree. I again went for the recursive approach of finding heights and cleared all test cases.

#### Round 2 (Technical I):

Interview took place on Skype. The recruiter focused mainly on the programming questions and less on projects:

1. Question on Trie – How to find the words ending with suffix ‘-ing’ in a dictionary. I could not answer it completely and the recruiter went on to next questions.
2. Given a matrix initialised with zeroes. There are queries based on indices- (i,j) and after each query, the ith row elements will increment with 1 and same goes for the jth column. After all the queries, we need to count the number of odd numbers in the matrix. I approached with naive approach which has O(k x n^2) complexity. But laterI optimized it based on the fact that even+even=even odd+odd=even and only the case of odd+even could bear an odd result.
3. Coin exchange problem- Minimum number of coins (using Greedy Approach) to make up a particular sum.
4. Reversing a liked list and reversing it again to retrieve the original linked list back. I solved it using recursive approach.
5. The number of nodes at a certain level of a Binary Tree. This can be solved easily by hashing.
6. Brief intro of projects and whawas my role in the projects.

The recruiter was supportive and the round was very smooth one. The questions were missing a lot of parts that the recruiter wanted me to ask and then move forward.

#### Round 3(Technical II):

The interview was again on Skype but this time the video of the recruiter was turned off, which was confusing at first but then I adapted to it. This round focused equally on both-coding as well as projects.

1. Explain your projects, your skills and interests. The reason behind using the technology I had used which I explained in detail.
2. Questions on the properties of Nodejs (Asynchronous, event-driven, threading etc), Reactjs(HOC, Lifecycle functions), JSON Format and Javascript Web Tokens that I used in my projects. I knew the answers to these questions which made the recruiter quite satisfied.
3. Code snippet on creating a server using express, which Idid on my text editor and shared the screen.
4. Given a matrix having some duplicate rows. Give the similar row indeices in the output. I solved it using hashing the rows with indices array. Though I couldn’t optimize it any further, the recruiter explained the solution using Trie.
5. Various Linked List and Binary Tree questions based on Recursion ( Reversing, Check Mirror, Check Symmetric) which I easily cleared and explained the sudo code with test cases.
6. A problem based on doubly linked list- There are continuous people coming to the queue and they must enter the queue at the location where they belong according to their heights in descending order. I explained the solution and he was satisfied with it.

The recruiter then asked if I had any questions, I asked him about the technologies he is working on. The recruiter was friendly and even excused the sudden power cut that took place while the interview. It was a a great interview experience and a quite enlightening one. I received the information of my selection a few hours later of my second interview. Even when I was not sure of my solution I communicated with the recruiter on my approach and he gave me a few hints using which the questions were solved.