Total 180 students appeared for Sabre onsite recruitment, Out of which 5 were selected. The process involved total four rounds. I will try to walk you through my experience and also give you some tips/advice for each round.

Round 1 – Online Test

Short Description – This round consisted of 40 MCQs and two coding questions. Webcam was ON during the process.

**Details – **

MCQ section covered all the main subjects of computer science (DBMS, Operating System, Data Structures & Algorithm, Computer Networks) and range of aptitude questions from various topics (BODMAS, Permutation, Distance and time, Compound Interest, Data Interpretation, Percentage, Loss and profit, Time and days). Few MCQ consisted of predicting output of C programs.

Coding section had two coding questions. First question was of 50 marks (easy). Second question was of 100 marks (super easy).

Coding Question 1 statement – You are given an array of integers of length n. Find the value G for the array. G is the maximum value of the magic number for each element of the array. For some element A[i], the magic number is the maximum prime divisor of x, where x is the number of elements in the given array strictly smaller than A[i]. Magic number = 0 {if x is 0}, Magic number = 1 {if x is 1}.

Example 1 - 
Input -
A[] = {1,4,5,6}
Output - 5 

Explanation -
magic number for 1 => 1
magic number for 4 => 2
magic number for 5 => 5
magic number for 6 => 3

so g = maximum of all = 5

Note – Language is confusing but question is easy.

**Solution **– Sort the given array. Initialize g = 1. Start iterating from 1st index. Maintain a variable (LESS=0, because there is 0 element smaller than smallest element) to store the number of elements smaller than the previous element (A[i-1]). If current element(A[i]) is equal to previous element(A[i-1]) then LESS remains same, else if current is greater than previous element then LESS = i (if we are on index 4 and A[3]<A[4] then all 0,1,2,3 are smaller). Find the max prime divisor for the value LESS. If this value is greater than g, update it. To find the max prime divisor for some number you may use divide till square root of number method. This isn’t the best solution but it was sufficient to pass all the test cases.

Coding Question 2 statement – You are given a string (sentence, may contain spaces) S1 and string S2. And a character variable C which can have value ‘Y’ or ‘N’. If the value of C is ‘Y’ , find if string S2 is present as a complete word in sentence. If the value of C is ‘N’ , find if string S2 is present in sentence S1 (not necessarily as complete world).

Example 1\. 
S1 = “geeksforgeeks is the best” 
S2 = “geeks”
C = “Y”
Output : not present
Explanation : as the value of C is ‘Y’ so S2 should 
be present as a complete word.
S2 is present in S1 but not as a complete word.

Example 2\. 
S1 = “geeksforgeeks is the best” 
S2 = “geeks”
C = “N”
Output : present
Explanation : as the value of C is ‘N’
so, S2 should be present and not necessarily
as a complete word. S2 is present in S1\. So output is present.

Note – Constraint is pretty small (|S1|,|S2| <= 50) so it will pass easily.

**Solution **– Check if the S2 is present in S1 or not by considering each index (i) of S1 as starting position. If C is ‘Y’ then check additionally if the S2 is complete word ( { i-1 < 0 or S1[i-1]==’ ‘ } and { S1[i+1] == ‘\0’ or S1[i+1]==’ ‘ } )

Advice for this round –

  1. Most of the aptitude questions are easy to crack. No extra preparation is needed. But you may try a few data interpretation questions.
  2. Study time complexity analysis problems thoroughly.
  3. Study Operating System seriously.
  4. Don’t forget to practice SQL syntax problems.
  5. You may leave or give little time to Computer Networks.
  6. It will be better if you write unoptimized code in this round. It will help you in the next round when the interviewer will ask you to optimize your solution.

#interview experiences #marketing #on-campus #sabre

Sabre Interview Experience | NIT Patna - SDE
2.70 GEEK