# Nutanix Interview (On Campus for Internships)

Recently, Nutanix visited our campus for hiring Interns. The process was similar to whats there for most of the companies. Initially, there was a coding test which had 2 questions in 1 hour. First question was an implementation of a binary search. It did not take me much time to strike that the question was binary search. There were 2 types of queries, each a different form of binary search. O(n^2) solution would pass 6/9 cases and a O(nlogn) solution would pass all the test cases. 2nd question was a tricky modification of counting inversions. I found this little hard as I hard less time left as well. But it turned out doing one complete question was enough to get qualified for the interviews. Remember, one complete problem is usually given more preference than 2 brute force attempts. For example, 9/9 cases in one question is better than 6/9 + 6/9 in two questions.

11 people were selected for interviews. The first round of interviews was surprisingly a written round. We were given a 2 page code the purpose of which was to merge sort a linked list while removing duplicates and we had to point out errors in the CORE LOGIC of the program and not give silly errors like semi-colons or de-referencing pointers. I think I found about 4 or 5 good errors in the code. 7 people were selected for the 2nd round. In my interview, the first question was, given a ternary operator string, for example, a?b?c:d:e, we had to convert it into a tree form.

https://www.geeksforgeeks.org/convert-ternary-expression-binary-tree/

It took me some time to do this problem, around 25-30 mins including writing the code. The interviewer was impressed and asked me a second question which was based on dynamic programming.

https://www.interviewbit.com/problems/ways-to-decode/

This was the second question. I did not take me much time to solve this problem and the interviewer was very much impressed.

After this, I had an HR round after which I was told that I had been selected for the Internship and I was extremely happy after that.

## Please

Loginto comment...