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

SDE - Intern

OYO
upvote
share-icon
3 rounds | 10 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 3 months
Topics: Data Structure,Algorithms,OS,DBMS,OOPS
Tip
Tip

Tip 1 : Work on communicating effectively, give a lot of mock interviews. There is no point studying so hard if your thoughts or solution don't reach the interviewer.
Tip 2 : Practice variety of questions. 50 questions of different topics, patterns are better that 50 questions done for same topic.
Tip 3 : Try to think of solution by different approaches, this will expand your horizon by doing less questions.

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

Tip 1 : Don't make a fancy resume, keep it simple, you can use Latex templates from overleaf.com.
Tip 2 : Make it short and crisp. Resume should not be more than 1 page. And don't write anything you're not confident about. For experienced people, read the JD first and design your resume accordingly.

Interview rounds

01
Round
Medium
Online Coding Interview
Duration60 minutes
Interview date2 Sep 2019
Coding problem2

1. Longest Increasing Subsequence

Moderate
30m average time
65% success
0/80
Asked in companies
Paytm (One97 Communications Limited)VisaOYO

For a given array with N elements, you need to find the length of the longest subsequence from the array such that all the elements of the subsequence are sorted in strictly increasing order.

Strictly Increasing Sequence is when each term in the sequence is larger than the preceding term.

For example:
[1, 2, 3, 4] is a strictly increasing array, while [2, 1, 4, 3] is not.
Problem approach

Used DP

Try solving now

2. Digits Decoding

Moderate
25m average time
70% success
0/80
Asked in companies
FacebookAdobeInfosys

A few days back, Ninja encountered a string containing characters from ‘A’ to ‘Z’ which indicated a secret message. For security purposes he encoded each character of the string to its numeric value, that is, A = 1, B = 2, C = 3, till Z = 26 and combined them as a single sequence (SEQ) of digits of length N. Let's say the message was "LA", Ninja encoded it as 121 for L=12 and A=1.

Today, when he read the encoded secret message, he realised that he was not able to decode the original string. So, the Ninja is wondering in how many ways he can decode the numeric sequence to some valid string.

A valid string is a string with characters from A to Z and no other characters.

Example:
Let the encoded sequence be 121,

The first way to decode 121 is:
1 = A
2 = B
1 = A
Thus, the decoded string will be ABA.

The second way to decode 121 is:
12 = L
1 = A
Thus, the decoded string will be LA.

The third way to decode 121 is:
1 = A
21 = U
Thus, the decoded string will be AU.

So, there will be 3 ways to decode the sequence 121 i.e. [(ABA), (LA), (AU)].
Note:
The input sequence will always have at least 1 possible way to decode.    

As the answer can be large, return your answer modulo 10^9  + 7.
Follow Up:
Can you solve this using constant extra space?
Problem approach

Used DP

Try solving now
02
Round
Medium
Face to Face
Duration60 minutes
Interview date5 Sep 2019
Coding problem2

1. Leaves at same level

Moderate
30m average time
80% success
0/80
Asked in companies
JP MorganOYOSamsung

Bob has been given a binary tree having N nodes. He has been asked to check if all the leaf nodes are at the same level.

Your task is to help Bob in checking if all the leaf nodes are at the same level or not. Return true if all the leaf nodes are at the same level otherwise return false.

A binary tree is a hierarchical data structure in which each node has at most two children.

Any node whose left and right child are null is called a leaf node in a binary tree.

Example:
Consider the given binary tree:

For the given tree the leaf nodes are 5, 4, 7, 6. All these nodes are on the same level. So the output will be True. 
Problem approach

I gave a level-order traversal solution using queue and then he asked me to optimise it to O(1) space.

Try solving now

2. Maximum sum of non-adjacent elements

Moderate
15m average time
85% success
0/80
Asked in companies
Expedia GroupOYOOLX Group

You are given an array/list of ‘N’ integers. You are supposed to return the maximum sum of the subsequence with the constraint that no two elements are adjacent in the given array/list.

Note:
A subsequence of an array/list is obtained by deleting some number of elements (can be zero) from the array/list, leaving the remaining elements in their original order.
Problem approach

Gave him a recursive solution then optimised it using DP(to O(n) time and O(n) space) and then again optimised to O(1) space.

Try solving now
03
Round
Medium
Face to Face
Duration60 minutes
Interview date5 Sep 2019
Coding problem6

1. LRU Cache Implementation

Moderate
25m average time
65% success
0/80
Asked in companies
ZomatoQualcommOracle

Design and implement a data structure for Least Recently Used (LRU) cache to support the following operations:

1. get(key) - Return the value of the key if the key exists in the cache, otherwise return -1.

2. put(key, value), Insert the value in the cache if the key is not already present or update the value of the given key if the key is already present. When the cache reaches its capacity, it should invalidate the least recently used item before inserting the new item.
You will be given ‘Q’ queries. Each query will belong to one of these two types:
Type 0: for get(key) operation.
Type 1: for put(key, value) operation.
Note :
1. The cache is initialized with a capacity (the maximum number of unique keys it can hold at a time).

2. Access to an item or key is defined as a get or a put operation on the key. The least recently used key is the one with the oldest access time.
Problem approach

Code this problem beforehand. It's a very common problem.

Try solving now

2. Doors Puzzle

There are 100 doors in a row, all doors are initially closed. A person walks through all doors multiple times and toggle (if open then close, if close then open) them in following way: 

In first walk, the person toggles every door 

In second walk, the person toggles every second door, i.e., 2nd, 4th, 6th, 8th, … 

In third walk, the person toggles every third door, i.e. 3rd, 6th, 9th, …

In 100th walk, the person toggles 100th door. 

Which doors are open in the end? 

Problem approach

Practise puzzles from gfg

3. Operating System

Tell the difference between Mutex and semaphores.

Problem approach

Study OS nicely.

4. DBMS

What is Indexing, why it is done and explain all the types of Indexing?

Problem approach

Study nicely.

5. DBMS

Given employee and dept table find the no of employees in each dept(Question on Joins).

Problem approach

Study SQL queries nicely.

6. OOPS Questions

Difference between function overloading and function overriding with example. And also about runtime and compile time binding while overriding.

Here's your problem of the day

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

Skill covered: Programming

Which operator is used for exponentiation in Python?

Choose another skill to practice
Similar interview experiences
company logo
SDE - Intern
3 rounds | 6 problems
Interviewed by OYO
2530 views
0 comments
0 upvotes
company logo
SDE - Intern
3 rounds | 3 problems
Interviewed by OYO
1547 views
0 comments
0 upvotes
company logo
SDE - Intern
1 rounds | 2 problems
Interviewed by OYO
962 views
0 comments
0 upvotes
company logo
SDE - Intern
3 rounds | 4 problems
Interviewed by OYO
937 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
SDE - Intern
3 rounds | 6 problems
Interviewed by Amazon
13856 views
4 comments
0 upvotes
company logo
SDE - Intern
4 rounds | 7 problems
Interviewed by Microsoft
13096 views
1 comments
0 upvotes
company logo
SDE - Intern
2 rounds | 4 problems
Interviewed by Amazon
9196 views
2 comments
0 upvotes