MMT | 6 yrs experience | Lead Engineer

makemytrip logo
makemytrip
Lead Engineer6 years
April 20, 20231 reads

Summary

I interviewed for a Lead Engineer position at MakeMyTrip, which involved three technical rounds. The interviews covered a range of topics including multithreading, linked list manipulation, array problems, and extensive system design focusing on microservices and workflow orchestration.

Full Experience

Round 1: Problem Solving & Concurrency

The first round kicked off with two coding challenges. The initial problem involved concurrency, requiring me to demonstrate my understanding of multithreading. Following that, I tackled a problem related to linked lists that tested my logic for sorting based on specific criteria.

  • Question 1: Print Even and Odd Numbers with Two Threads

    I was asked to implement a solution to print even and odd numbers using two separate threads. Thread 1 should print even numbers, and Thread 2 should print odd numbers.

  • Question 2: Sort Linked List by Actual Value (Absolute Sorted)

    I was given a linked list of integers that was sorted by their absolute values. The task was to sort this linked list by their actual values. For instance, if the input is 1 -> -2 → 3 → -4 → 5 → -6, the expected output should be -6 → -4 → -2 → 1 → 3 → 5.

Round 2: Data Structures & System Design

The second round was a mix of a standard data structure problem and an initial foray into system design. I first solved an array manipulation problem, and then moved onto designing a critical service for the company's domain.

  • Question 1: Product of Array Except Self

    I needed to construct a product array prod[] of the same size as the input array arr[] of n integers. Each element prod[i] should be equal to the product of all elements of arr[] except arr[i].

  • Question 2: Design Hotel Search and Ranking Service

    I was asked to design a system for hotel search and ranking. The inputs include city name, search criteria (check-in, check-out, number of adults, rooms). The system should involve a 'Search service' and a 'Hotels Ranking service' (microservice). I needed to discuss how ranking modulation would work for different users, considering factors like user footprint, giving higher rank for the same place, budget preferences (e.g., budget on iPhone), lower prices for small cities, and IP-based considerations.

Round 3: Advanced System Design

The final round was entirely focused on a complex system design problem, specifically concerning workflow orchestration. This round required me to think about task dependencies, parallel execution, and data flow between different stages of a workflow.

  • Question 1: Design Workflow Orchestration Service

    The task was to design a workflow service capable of running tasks both in parallel and sequentially. I was given examples like workflow1 where tasks T1 and T2 run in parallel, followed by T3 which executes only if T1 and T2 are successful, and then T4, T5, T6, T7. Another example W2 showed T1, T2, T3, T4, T5 running in a specific sequence. A key requirement was the ability to pass outputs from previous steps to subsequent ones.

Interview Questions (5)

Q1
Print Even and Odd Numbers with Two Threads
Other

I was asked to implement a solution to print even and odd numbers using two separate threads. Thread 1 should print even numbers, and Thread 2 should print odd numbers.

Q2
Sort Linked List by Actual Value (Absolute Sorted)
Data Structures & Algorithms

I was given a linked list of integers that was sorted by their absolute values. The task was to sort this linked list by their actual values. For instance, if the input is 1 -> -2 → 3 → -4 → 5 → -6, the expected output should be -6 → -4 → -2 → 1 → 3 → 5.

Q3
Product of Array Except Self
Data Structures & Algorithms

I needed to construct a product array prod[] of the same size as the input array arr[] of n integers. Each element prod[i] should be equal to the product of all elements of arr[] except arr[i].

Q4
Design Hotel Search and Ranking Service
System Design

I was asked to design a system for hotel search and ranking. The inputs include city name, search criteria (check-in, check-out, number of adults, rooms). The system should involve a 'Search service' and a 'Hotels Ranking service' (microservice). I needed to discuss how ranking modulation would work for different users, considering factors like user footprint, giving higher rank for the same place, budget preferences (e.g., budget on iPhone), lower prices for small cities, and IP-based considerations.

Q5
Design Workflow Orchestration Service
System Design

The task was to design a workflow service capable of running tasks both in parallel and sequentially. I was given examples like workflow1 where tasks T1 and T2 run in parallel, followed by T3 which executes only if T1 and T2 are successful, and then T4, T5, T6, T7. Another example W2 showed T1, T2, T3, T4, T5 running in a specific sequence. A key requirement was the ability to pass outputs from previous steps to subsequent ones.

Discussion (0)

Share your thoughts and ask questions

Join the Discussion

Sign in with Google to share your thoughts and ask questions

No comments yet

Be the first to share your thoughts and start the discussion!