Ola interview experience Real time questions & tips from candidates to crack your interview

SDE - 1

Ola
upvote
share-icon
4 rounds | 7 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 3 months
Topics: Data Structures, OOPS, Algorithms, Puzzles, Binary Search, Dynamic Programming.
Tip
Tip

Tip 1 : Go through standard problems
Tip 2 : You should know about everything you have written on your resume

Application process
Where: Campus
Eligibility: Above 7 CGPA
Resume Tip
Resume tip

Tip 1 : Keep it short not more than 1 page.
Tip 2 : Write more about figures and technicality on your resume.

Interview rounds

01
Round
Medium
Online Coding Interview
Duration90 minutes
Interview date9 Nov 2019
Coding problem3

It was in the morning, where there were 3 questions to answer.

1. Find Number Of Islands

Moderate
34m average time
60% success
0/80
Asked in companies
MicrosoftAmazonUber

You are given a 2-dimensional array/list having N rows and M columns, which is filled with ones(1) and zeroes(0). 1 signifies land, and 0 signifies water.

A cell is said to be connected to another cell, if one cell lies immediately next to the other cell, in any of the eight directions (two vertical, two horizontal, and four diagonals).

A group of connected cells having value 1 is called an island. Your task is to find the number of such islands present in the matrix.

Problem approach

A cell in 2D matrix can be connected to 8 neighbours. So, unlike standard DFS(), where we recursively call for all adjacent vertices, here we can recursively call for 8 neighbours only. We keep track of the visited 1s so that they are not visited again.

Try solving now

2. Missing Numbers

Easy
28m average time
85% success
0/40
Asked in companies
Thought WorksAdobeAmazon

You are given an array 'ARR' of distinct positive integers. You need to find all numbers that are in the range of the elements of the array, but not in the array. The missing elements should be printed in sorted order.

Example:
If the given array is [4, 2, 9] then you should print "3 5 6 7 8". As all these elements lie in the range but not present in the array.
Problem approach

The length of the array is n-1. So the sum of all n elements, i.e sum of numbers from 1 to n can be calculated using the formula n*(n+1)/2. Now find the sum of all the elements in the array and subtract it from the sum of first n natural numbers, it will be the value of the missing element.

Try solving now

3. Count Leaf Nodes

Easy
10m average time
90% success
0/40
Asked in companies
SamsungOlaSlice

You are given a Binary tree. You have to count and return the number of leaf nodes present in it.

A binary tree is a tree data structure in which each node has at most two children, which are referred to as the left child and the right child

A node is a leaf node if both left and right child nodes of it are NULL.

Problem approach

The idea is to use level order traversal. During traversal, if we find a node whose left and right children are NULL, we increment count.

Try solving now
02
Round
Medium
Face to Face
Duration20 minutes
Interview date2 Dec 2019
Coding problem1

It was a system design round.

1. System Design Question

System Design of OLA App

Problem approach

Tip 1 : Talk About the Challenges
Tip 2 : How Dispatch System Works?
Tip 3 : Supply Service And How it Works?
Tip 4 : Demand Service And How it Works?
Tip 5 : How Dispatch System Match the Riders to Drivers?
Tip 6 : How To Scale Dispatch System?
Tip 7 : How Uber Builds the Map?
Tip 8 : How ETAs Are Calculated?

03
Round
Medium
Face to Face
Duration45 minutes
Interview date2 Dec 2019
Coding problem2

It was a DS Algo round.

1. Diagonal Traversal of a Binary Tree

Easy
10m average time
90% success
0/40
Asked in companies
OlaExpedia GroupAmazon

You have been given a binary tree of integers. You are supposed to find the diagonal traversal(refer to Example) of the given binary tree.

Example:

Consider lines at an angle of 135 degrees(with respect to standard X- axis)  in between nodes. Then, all nodes between two consecutive lines belong to the same diagonal

alt text

The diagonal traversal for the above tree is: 

0 2 6 1 5 3 4 7 
Problem approach

The idea is to use a map. We use different slope distances and use them as key in the map. Value in the map is a vector (or dynamic array) of nodes. We traverse the tree to store values in the map. Once map is built, we print the contents of it.

Try solving now

2. Minimum Number Of Taps To Water Garden

Hard
15m average time
85% success
0/120
Asked in companies
AppleBNY MellonOla

The gardener wants to water the garden by opening the minimum number of taps. The garden is one-dimensional along the x-axis of length N i.e. the garden starts from point 0 and ends at point N. There are N + 1 tap located at points [0, 1, 2, …, N] in the garden.

You are given an integer N, and an array named “ranges” of size N + 1(0-indexed). The ith tap, if opened, can water the gardener from point (i - ranges[i]) to (i + ranges[i]) including both. The task is to find the minimum number of taps that should be open to water the whole garden, return -1 if the garden can not be watered.

Example :

Watering The Garden

Follow Up:
Can you solve the problem in O(N) time?
Problem approach

The idea is to first sort the range by left boundary and then traversing ranges from left and in each iteration select the rightmost boundary a sprinkler can cover having the left boundary in the current range

Try solving now
04
Round
Medium
HR Round
Duration15 minutes
Interview date2 Dec 2019
Coding problem1

HR Round

1. Basic HR Questions

Why do you want to join this company?

Where do you see yourself in coming years?

Problem approach

Tip 1 : Always say what the HR wants to listen.
Tip 2 : Make them believe that you'll be completely committed towards their organisation
Tip 3 : Never mention if you are planning for higher studies

Here's your problem of the day

Solving this problem will increase your chance to get selected in this company

Skill covered: Programming

What is recursion?

Choose another skill to practice
Similar interview experiences
company logo
SDE - 1
4 rounds | 5 problems
Interviewed by Ola
1645 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 4 problems
Interviewed by Ola
1217 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 6 problems
Interviewed by Ola
0 views
0 comments
0 upvotes
company logo
SDE - 1
2 rounds | 4 problems
Interviewed by Ola
951 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
SDE - 1
5 rounds | 12 problems
Interviewed by Amazon
114579 views
24 comments
0 upvotes
company logo
SDE - 1
4 rounds | 5 problems
Interviewed by Microsoft
57825 views
5 comments
0 upvotes
company logo
SDE - 1
3 rounds | 7 problems
Interviewed by Amazon
34961 views
7 comments
0 upvotes