i
MakeMyTrip
Filter interviews by
Clear (1)
I was interviewed in Sep 2021.
Round duration - 60 Minutes
Round difficulty - Medium
The test was in the morning at around 11.
It was on online assessment.
HackerEarth was perfect like everytime.\
MCQ were based on HTML ,CSS , JS, OOPS, SQL, Aptitude, OS.
You are given a source point (sx, sy) and a destination point (dx, dy). Determine if it is possible to reach the destination point using only the following valid mo...
The problem involves determining if it is possible to reach a destination point from a source point using specified moves.
Iterate through each test case and check if destination is reachable from source using specified moves
Implement a recursive function to explore all possible paths from source to destination
Keep track of visited points to avoid infinite loops
Return true if destination is reachable, false otherwise
You are provided with a Binary Search Tree (BST) containing 'N' nodes with integer data. Your task is to remove a given node from this BST.
A BST is a ...
Implement a function to delete a node from a Binary Search Tree and return the inorder traversal of the modified BST.
Understand the properties of a Binary Search Tree (BST) - left subtree contains nodes with data less than the node, right subtree contains nodes with data greater than the node.
Implement a function to delete the given node from the BST while maintaining the BST properties.
Perform inorder traversal of the...
Round duration - 90 Minutes
Round difficulty - Hard
The interviewer was very friendly. He gave me problems one by one and asked me to write code for all of them in Code Pair round. Explain Scope and Scope Chain in javascript. What is a Stored Procedure in SQL?
Given a binary matrix of size N * M
where each element is either 0 or 1, find the shortest path from a source cell to a destination cell, consisting only...
Find the shortest path in a binary matrix from a source cell to a destination cell consisting only of 1s.
Use Breadth First Search (BFS) algorithm to find the shortest path.
Keep track of visited cells to avoid revisiting them.
Calculate the path length by counting the number of 1s in the path.
Handle edge cases such as invalid inputs and unreachable destination.
You are given an integer array 'ARR' of size 'N' and an integer 'S'. Your task is to find and return a list of all pairs of elements where each sum of a pair equals 'S'.
Given an array of integers and a target sum, find all pairs of elements that add up to the target sum.
Use a hashmap to store the difference between the target sum and each element as keys and their indices as values.
Iterate through the array and check if the current element's complement exists in the hashmap.
Return the pairs of elements that add up to the target sum in sorted order.
You are given a binary tree with 'N' integer nodes. Your task is to determine whether this binary tree is a Binary Search Tree (BST).
A Binary Search Tr...
Validate if a given binary tree is a Binary Search Tree (BST) or not.
Check if the left subtree of a node contains only nodes with data less than the node's data.
Check if the right subtree of a node contains only nodes with data greater than the node's data.
Ensure that both the left and right subtrees are also binary search trees.
Traverse the tree in an inorder manner and check if the elements are in sorted order.
Recurs...
Round duration - 45 minutes
Round difficulty - Medium
The round was with CTO level person. He was very friendly. What is the difference between SQL and MySQL? What are Constraints in SQL?
You are provided with a string 'S'. The task is to determine the length of the longest duplicate substring within this string. Note that duplicate substrings ...
Find the length of the longest duplicate substring in a given string.
Iterate through all possible substrings of the input string.
Use a rolling hash function to efficiently compare substrings.
Store the lengths of duplicate substrings and return the maximum length.
You are given an array ARR
consisting of N
elements. Your task is to determine the maximum value of the summation of i * ARR[i]
among all possible rotations of ...
Find the maximum sum of products for array rotations.
Iterate through all possible rotations of the array and calculate the sum of products for each rotation.
Keep track of the maximum sum of products found so far.
Return the maximum sum of products obtained.
Tip 1 : DSA should be very very good.
Tip 2 : Computer Science Fundamentals are very important
Tip 3 : Think out loud in an interview
Tip 1 : At least 2 very well prepared projects
Tip 2 : Internship experiences always help
I was interviewed in Sep 2021.
Round duration - 90 minutes
Round difficulty - Easy
2 Coding Questions and 20 MCQ's to be solved in 90 minutes. It was from 6 pm. The camera and screen-recorders were on. The mcq was on web, oops, dbms.
You have a 2D grid of dimensions 'N' rows by 'M' columns, initially filled with water. You are given 'Q' queries, where each query contains two integers 'X' and 'Y'....
The task is to determine the number of islands present on a 2D grid after each query of converting water to land.
Create a function that takes the grid dimensions, number of queries, and query coordinates as input.
For each query, convert the water at the given coordinates to land and then count the number of islands on the grid.
Use depth-first search (DFS) or breadth-first search (BFS) to identify connected land cells f...
Given an integer array, your objective is to change all elements to the same value, minimizing the cost. The cost of changing an element from x
to y
is defined ...
Find the minimum cost to make all elements of an array equal by changing them to the same value.
Calculate the median of the array and find the sum of absolute differences between each element and the median.
Sort the array and find the median element, then calculate the sum of absolute differences between each element and the median.
If the array has an even number of elements, consider the average of the two middle elem
Round duration - 70 minutes
Round difficulty - Medium
The interview started with the interviewer asking me about my projects and why and what I have used in them. Be very clear with all the technologies you have used in your project as the interviewer will ask you in-depth about it.
Explain Components, Modules and Services in Angular. What is a Recursive Stored Procedure?
You are given an integer array ARR
. Determine the length of the shortest contiguous subarray which, when sorted in ascending order, results in the entire array being sorted in a...
Determine the length of the shortest contiguous subarray that needs to be sorted to make the entire array sorted in ascending order.
Iterate from left to right to find the first element out of order.
Iterate from right to left to find the last element out of order.
Calculate the length of the subarray between the two out of order elements.
You are given an array 'ARR'
of size 'N'
consisting of positive integers. Your task is to determine the minimum number of operations required to make all elements in t...
Minimum number of operations to make all elements in an array equal by performing addition, subtraction, multiplication, or division.
Iterate through the array to find the maximum and minimum elements.
Calculate the difference between the maximum and minimum elements.
The minimum number of operations needed is the difference between the maximum and minimum elements.
You have three rods numbered from 1 to 3, and 'N' disks initially stacked on the first rod in increasing order of their sizes (largest disk at the bottom). Your task is to...
Tower of Hanoi problem involves moving 'N' disks from one rod to another following specific rules in less than 2^N moves.
Implement a recursive function to move disks from one rod to another while following the rules.
Use the concept of recursion and backtracking to solve the Tower of Hanoi problem efficiently.
Maintain a count of moves and track the movement of disks in a 2-D array/list.
Ensure that larger disks are not p...
Multithreading allows multiple threads to run concurrently, while semaphores are used to control access to shared resources in a synchronized manner.
Multithreading involves running multiple threads within a single process, allowing for parallel execution of tasks.
Semaphores are used to control access to shared resources by allowing only a certain number of threads to access the resource at a time.
Semaphores can be bina...
Round duration - 30 minutes
Round difficulty - Easy
The interviewer was VP of Engineering at MakeMyTrip with more than 10 years of experience. He asked about the 4 Pillars of OOPS and we had an in-depth discussion with real-life applications for each of them.
You are provided with two integers, 'N' and 'D'. Your objective is to determine the square root of the number 'N' with a precision up to 'D' decimal pl...
Implement a function to find the square root of a number with a given precision.
Create a function that takes 'N' and 'D' as input parameters
Use a mathematical algorithm like Newton's method to approximate the square root
Iterate until the precision condition is met
Return the square root with the required precision
Tip 1 : Never lose hope. Just keep working.
Tip 2 : Solve at least 5 problems each day of medium level or 3 questions of hard level with complete understanding.
Tip 3 : Keep at least 3-4 projects in your resume.
Tip 1 : Keep it 1 page.
Tip 2 : Revise it very well before the interview.
Tip 3 : Know your projects in-depth. They might also ask you to show a demo as it is a virtual interview. So, keep them ready before the interview.
I was interviewed in Aug 2021.
Round duration - 120 Minutes
Round difficulty - Medium
There were two sections mcq's and coding. We were allowed to switch between sections and there was no specific time for any section. Around 350 students gave the test.
Given an integer array ARR
of size N
, your task is to find the total number of inversions that exist in the array.
An inversion is defined for a pair of integers in the...
Count the total number of inversions in an integer array.
Iterate through the array and for each pair of elements, check if the inversion condition is met.
Use a nested loop to compare each pair of elements efficiently.
Keep a count of the inversions found and return the total count at the end.
Given a binary array 'ARR' of size 'N', your task is to determine the maximum length of a sequence consisting solely of 1’s that can be obtained by converting at...
Find the maximum length of a sequence of 1's by converting at most K zeroes into ones in a binary array.
Iterate through the array and keep track of the current window of 1's and zeroes.
Use a sliding window approach to find the maximum length of the sequence.
Update the window by flipping zeroes to ones within the limit of K flips.
Return the maximum length of the sequence obtained.
Round duration - 50 Minutes
Round difficulty - Medium
About 45 students were shortlisted for this round. My interview was at 10:15am. I was asked to introduce myself.
Given an integer array 'A' of size N, your task is to find the maximum value of j - i, with the restriction that A[i] <= A[j], where 'i' and 'j' are indices of the ar...
Find the maximum distance between two elements in an array where the element at the first index is less than or equal to the element at the second index.
Iterate through the array and keep track of the minimum element encountered so far along with its index.
Calculate the maximum distance by subtracting the current index from the index of the minimum element.
Update the maximum distance if a greater distance is found whil...
You are given a binary tree of integers. Your task is to determine the left view of the binary tree. The left view consists of nodes that are visible when the tree...
The task is to determine the left view of a binary tree, which consists of nodes visible when viewed from the left side.
Traverse the binary tree level by level from left to right, keeping track of the first node encountered at each level.
Use a queue to perform level order traversal and keep track of the level number for each node.
Store the first node encountered at each level in a result array to get the left view of t
Round duration - 40 Minutes
Round difficulty - Easy
About 17 students cleared the first round. My second round was at 4:30pm. The interviewer was very humble.
Round duration - 20 Minutes
Round difficulty - Easy
This was HR round, 7 students were shortlisted for this round. I received the call after 6:30pm.
Tip 1 : For on campus placements, focus more on core subjects rather than very good projects/internships.
Tip 2 : You must cover all important Data Structures and their important/fundamental questions at least twice. For advanced Data Structures like DP, graph, trees, you should have good practice before hand.
Tip 3 : Solve aptitude questions occasionally.
Tip 1 : Don't put too much skills/projects if you are not confident about it, u need not have very rich resume during on campus placements
Tip 2 : it should be readable and authentic
Top trending discussions
The function checks if a string is a substring of another string.
Use the built-in string methods like 'indexOf' or 'includes' to check for substring.
If the language supports regular expressions, you can also use them to find substrings.
Consider the case sensitivity of the strings when comparing.
Code to multiply two matrices of dimension M*N and N*K.
Create a result matrix of dimension M*K.
Iterate through each row of the first matrix.
For each row, iterate through each column of the second matrix.
For each element in the row of the first matrix, multiply it with the corresponding element in the column of the second matrix.
Sum up the products and store the result in the corresponding position of the result matrix.
...
SQL query to perform matrix multiplication using two tables with row, col, and value columns.
Use JOIN operation to combine the two tables based on matching row and col values.
Use GROUP BY clause to group the result by row and col values.
Use SUM function to calculate the dot product of corresponding row and col values.
Use INSERT INTO statement to insert the result into a new table.
Prototype in JavaScript is an object that is associated with every function and object by default.
Prototype is used to add properties and methods to an object.
It allows objects to inherit properties and methods from other objects.
Modifying the prototype of a function affects all instances of that function.
Prototypes can be used to create new objects based on existing objects.
The prototype chain allows for property and
Classes in JavaScript are written using the class keyword.
Use the class keyword followed by the class name to define a class.
Use the constructor method to initialize class properties.
Add methods to the class using the class prototype.
Use the new keyword to create an instance of the class.
The number of different ways to climb a ladder of N steps by taking 1 or 2 steps at a time.
This is a classic problem that can be solved using dynamic programming.
The number of ways to climb N steps is equal to the sum of the number of ways to climb N-1 steps and N-2 steps.
The base cases are when N is 0 or 1, where there is only 1 way to climb the ladder.
For example, for N=4, there are 5 different ways: [1, 1, 1, 1], [1
Print a square matrix in spiral order
Start by defining the boundaries of the matrix
Iterate through the matrix in a spiral pattern, printing each element
Adjust the boundaries after each iteration to move inward
Repeat until all elements are printed
Retrieve the second highest marks obtained by each student from a table with student name, subject, and marks.
Use the RANK() function to assign a rank to each row based on the marks in descending order.
Filter the result to only include rows with rank 2 for each student.
Group the result by student name to get the second highest marks for each student.
The .live() method attaches an event handler to the current and future elements, while .delegate() attaches an event handler to a parent element.
The .live() method is deprecated in newer versions of jQuery.
The .delegate() method is preferred over .live() for performance reasons.
Both methods are used to handle events for dynamically added elements.
Example: $(document).live('click', 'button', function() { ... });
Example:...
Chaining in jQuery allows multiple methods to be called on a single element in a single line of code.
Chaining simplifies code and improves readability.
Each method in the chain operates on the result of the previous method.
The chain ends with a method that does not return a jQuery object.
Example: $('div').addClass('highlight').fadeOut();
A callback function is a function that is passed as an argument to another function and is executed later.
Callback functions are commonly used in event-driven programming.
They allow asynchronous execution of code.
Callback functions can be used to handle responses from APIs or user interactions.
They can be anonymous functions or named functions.
Example: setTimeout(function() { console.log('Hello!'); }, 1000);
The .bind() function in jQuery is used to attach an event handler function to one or more elements.
It allows you to specify the event type and the function to be executed when the event occurs.
The .bind() function can be used to bind multiple events to the same element.
It can also be used to pass additional data to the event handler function.
The .bind() function is deprecated in jQuery version 3.0 and above. It is reco
The angle between the hour and minute hands of a clock can be calculated using a formula.
The hour hand moves 30 degrees per hour and 0.5 degrees per minute.
The minute hand moves 6 degrees per minute.
Calculate the angle between the two hands using the formula: |30H - 11M/2|, where H is the hour and M is the minute.
Yes, it is possible to create a slideshow without using JavaScript.
Use CSS animations and transitions to create the slideshow.
Use HTML and CSS to structure and style the slideshow.
Utilize keyframe animations to create the slide transitions.
Use radio buttons or checkboxes to control the slideshow navigation.
Apply the :target pseudo-class to create a simple slideshow without JavaScript.
The men can take turns riding the scooter, allowing them to reach point B faster.
The men can form a queue and take turns riding the scooter.
The person riding the scooter can drop it off at a certain point and the next person can pick it up.
The scooter can be passed along the line of men until everyone reaches point B.
Machine coding round
Developed a web application for managing inventory and sales for a retail store
Used React.js for front-end development
Implemented Node.js for back-end functionality
Utilized MongoDB for database management
I am a passionate software developer with experience in Java, Python, and web development.
Experienced in Java, Python, and web development technologies
Strong problem-solving skills
Team player with excellent communication skills
I was interviewed before Sep 2020.
Round duration - 75 minutes
Round difficulty - Easy
This was the online round held at university. All students who met the eligibility criteria were called for the online test on hackerrank.
Given two strings, 'STR1' and 'STR2', of equal lengths, determine the minimum number of manipulations required to make the two strings anagrams of each other.
The problem involves finding the minimum number of manipulations required to make two strings anagrams of each other.
Create frequency maps for both strings
Find the absolute difference in frequencies of each character
Sum up the absolute differences to get the total manipulations needed
Round duration - 90 Minutes
Round difficulty - Medium
This round was technical round and the interview started with formal introduction and general questions.
After that We had a discussion on LRU Cache.
Followed by coding and set of data structure questions.
You have a car with a gas tank of infinite capacity. There are 'N' gas stations located along a circular route, numbered from 0 to N-1. You begin your journey with an empty tank...
Find the starting gas station index to complete a circular route with gas and cost arrays.
Iterate through gas stations, keeping track of total gas and total cost from each station
If total gas is greater than or equal to total cost, update the starting station index
Return the starting station index if a valid one is found, else return -1
Round duration - 90 minutes
Round difficulty - Medium
This Round was DS and Algo round and it started with formal introduction, followed by 2 problems. We first dicussed the approach the time complexity and proper code covering all cases.
Given a binary tree of integers, your task is to print the boundary nodes of this binary tree in an anti-clockwise direction starting from the root node.
The fir...
Print the boundary nodes of a binary tree in an anti-clockwise direction starting from the root node.
Traverse the left boundary nodes from the root to the leftmost leaf node.
Traverse the leaf nodes from left to right.
Traverse the right boundary nodes from the rightmost leaf node to the root.
Given an integer array ARR
and a positive integer K
, your objective is to find two non-overlapping subarrays (contiguous) of length K
each, such that their sum...
Find two non-overlapping subarrays of length K with maximum sum in an integer array.
Iterate through the array to find all possible subarrays of length K.
Calculate the sum of each pair of non-overlapping subarrays of length K.
Keep track of the maximum sum obtained from the pairs of subarrays.
Round duration - 30 minutes
Round difficulty - Easy
This was the Final Interview and it started with formal introduction and general HR questions. Then We discussed about the projects and the things written in my resume. The interviewer was very frank and this round was very interactive. He asked me about my college, my future plans, teachers, various subjects, why Expedia and questions like that.
Tip 1 : Be solid with the basics of Ds & Algorithms. Good to have end to end projects which are hosted on cloud.
Tip 2 : Its always good to be presentable and have good communications skills
Tip 3 : Be honest, clear in approach and always walkthrough your thought process to the interviewer
Tip 1: Mention your projects and experience at the top. Be clear on what was done, a brief on how it was done, language /tech stack involved. If possible try to host and make it accessible. You never know if you can present it with just one click.
Tip 2: Choose a balance between, white spaces and text, it should be well indented, no grammatical errors.
Tip 3: It takes less than 2 min to scan a resume. Don't mention things which are irrelevant.
I was interviewed before Jan 2021.
Round duration - 120 minutes
Round difficulty - Easy
The test was divided into two parts : Section A had questions from Quantitative, C language, Logical and English. The second part had two coding questions.
Given a Circular Singly Linked List of integers, and a specific value 'VAL', your task is to delete the first occurrence of this value in the linked list...
Delete the first occurrence of a specific value in a Circular Linked List.
Traverse the circular linked list to find the value to be deleted.
Update the pointers to skip the node containing the value.
Handle edge cases like deleting the only node in the list.
Return the modified circular linked list.
Design a data structure for a Least Recently Used (LRU) cache that supports the following operations:
1. get(key)
- Return the value of the key if it exists in the cache; otherw...
Design a Least Recently Used (LRU) cache data structure that supports get and put operations with capacity constraints.
Use a combination of a doubly linked list and a hashmap to efficiently implement the LRU cache.
Keep track of the least recently used item and update it accordingly when new items are added.
Ensure that the cache does not exceed its capacity by evicting the least recently used item when necessary.
Tip 1 : Must do Previously asked Interview as well as Online Test Questions.
Tip 2 : Go through all the previous interview experiences from Codestudio and Leetcode.
Tip 3 : Do at-least 2 good projects and you must know every bit of them.
Tip 1 : Have at-least 2 good projects explained in short with all important points covered.
Tip 2 : Every skill must be mentioned.
Tip 3 : Focus on skills, projects and experiences more.
I was interviewed before Jan 2021.
Round duration - 120 minutes
Round difficulty - Easy
Hello everyone! Expedia came to our campus for full time hiring of final year students. They had shortlisted candidates for the interviews by taking an online test comprised of four sections (Quantitative, C, Logical and English). Every section had a timer attached to it, so you need to think and answer quickly. Although, the questions were easy but cutoff was quite high. This round was followed by a coding round, comprised of two questions.
You are provided with a Circular Linked List of integers and a specific integer, referred to as 'key'
.
Your task is to implement a function that locates the spec...
Implement a function to delete a specific key from a Circular Linked List of integers.
Traverse the Circular Linked List to find the key to be deleted.
Adjust the pointers to remove the node containing the key.
Handle the case where the Circular Linked List becomes empty after deletion.
Return -1 if the Circular Linked List is empty after deletion.
In computing, a page fault occurs when a process accesses a memory page that is not currently mapped by the memory management unit. To handle new pages being b...
The problem involves determining the number of page faults using the Least Recently Used (LRU) replacement algorithm.
Page faults occur when a process accesses a memory page not currently mapped by the memory management unit.
Page replacement algorithm like LRU is used to decide which existing page should be replaced.
The goal is to calculate the number of page faults based on the given input sequences and memory capacity...
Round duration - 60 minutes
Round difficulty - Easy
The man who was taking my first round was my alumni. He started-off by asking my introduction and then gave me 2 programming questions to code. He then navigated on to my Codechef profile and asked a question that I did in the June 14 Long Contest. I explained him and he was satisfied.
Tips : You don’t have to answer the stuffs quickly, rather you need to develop some test cases and have some discussion regarding the structure of the problem, and then answer.
Determine if a given singly linked list of integers forms a cycle or not.
A cycle in a linked list occurs when a node's next
points back to a previous node in the ...
Detect if a singly linked list forms a cycle by checking if a node's next points back to a previous node.
Traverse the linked list using two pointers, one moving one step at a time and the other moving two steps at a time.
If the two pointers meet at any point, it indicates the presence of a cycle in the linked list.
Use Floyd's Cycle Detection Algorithm for efficient detection of cycles in a linked list.
Given an array of integers ARR
of size N
and an integer target
, find three integers in ARR
such that their sum is closest to the target
. If there are two closest sums, return...
Find three integers in an array whose sum is closest to a given target, return the smallest sum if there are two closest sums.
Iterate through all possible triplets in the array to find the sum closest to the target.
Keep track of the closest sum found so far and update it if a closer sum is found.
Return the closest sum at the end of the iteration.
Tip 1 : Must do Previously asked Interview as well as Online Test Questions.
Tip 2 : Go through all the previous interview experiences from Codestudio and Leetcode.
Tip 3 : Do at-least 2 good projects and you must know every bit of them.
Tip 1 : Have at-least 2 good projects explained in short with all important points covered.
Tip 2 : Every skill must be mentioned.
Tip 3 : Focus on skills, projects and experiences more.
Senior Software Engineer
324
salaries
| ₹0 L/yr - ₹0 L/yr |
Assistant Manager
272
salaries
| ₹0 L/yr - ₹0 L/yr |
Senior Business Development Manager
226
salaries
| ₹0 L/yr - ₹0 L/yr |
Holiday Expert
225
salaries
| ₹0 L/yr - ₹0 L/yr |
Senior Executive
210
salaries
| ₹0 L/yr - ₹0 L/yr |
Cleartrip
Yatra
Goibibo
Oyo Rooms