Summary
I interviewed for an internship position at Rapyuta Robotics through an on-campus drive at NIT TRICHY and was ultimately rejected. The process involved four rounds: a written test, a behavioral HR interview, a technical discussion on DSA and OS, and a critical thinking puzzle.
Full Experience
Hi everyone, I am Mihir from NIT TRICHY. Rapyuta Robotics, a startup, visited our college for internship hiring. There were four rounds in total:
1. PPT Presentation
This was the initial round.
2. Round 1 - Written Test
This round consisted of mathematics, probability, algebra, puzzles, matrix-based questions, and other confusing problems. There were also three simple coding questions:
- Sort program in descending order
- Anagram in string
- Armstrong number
The main focus of the written test was on our thought process in mathematics.
3. Round 2 - Behavioral HR Round
This was a typical HR interview where I was asked about my family, previous studies, and my strengths and weaknesses.
4. Round 3 - Technical Round
In this round, the interviewer asked me about my strong topics on my resume, and I mentioned problem-solving in DSA. The questions included:
- A program to check for a leap year.
- A debugging question on the range of a
chardata type. The interviewer presented the following C++ code and asked me to explain its behavior:int main(){ char a; for(a =1 ; a<= 127 ;a++){ cout<<a<<" "; } cout<<endl; }I didn't give the full correct explanation during the interview, but the solution is that this code results in an infinite loop. When
areaches 127 anda++is executed, for a signedchar, it wraps around to -128 due to overflow. Since -128 is still less than or equal to 127, the loop condition remains true, leading to a Time Limit Exceeded (TLE). - Questions about operating systems, specifically threads, race conditions, critical section problems, and other in-depth questions.
5. Round 4 - Critical Thinking Round
I was given a puzzle to solve. The interviewer explained the concept of an 'invariant' – something that does not change at every step despite changes in the environment (e.g., the total energy in a falling object). Then, the puzzle was presented:
We have a sorted array of numbers from 1 to 100. There's an operation where any element arr[i-1] can swap with arr[i+1]. After some number of operations, can we make this array sorted in decreasing order? I also had to identify the invariant in this problem.
My solution was that an even-sized array can never be sorted in decreasing order because the last indexed number cannot move to the first position. Only odd-sized arrays can be converted to decreasing order. The invariant is that when we perform the operation, values at odd/even indexed positions always remain at odd/even indices before and after the operation.
Unfortunately, I was rejected for the internship after these rounds. I hope this interview experience finds you helpful. Thank you.
Interview Questions (7)
Write a program to sort an array of numbers in descending order.
Write a program to determine if two given strings are anagrams of each other.
Write a program to check if a given number is an Armstrong number.
Write a program to determine if a given year is a leap year.
Given the following C++ code, explain its behavior, specifically considering the range of the char data type (typically -128 to 127 for signed char):
int main(){
char a;
for(a =1 ; a<= 127 ;a++){
cout<<a<<" ";
}
cout<<endl;
}Discuss concepts related to operating systems, specifically focusing on threads, race conditions, critical section problems, and other in-depth related questions.
Given a sorted array of numbers from 1 to 100. An operation allows swapping arr[i-1] with arr[i+1] for any valid index i. After some number of operations, can this array be made sorted in decreasing order? Additionally, identify the invariant in this problem.