Paytm (One97 Communications Limited) interview experience Real time questions & tips from candidates to crack your interview

Software Engineer

Paytm (One97 Communications Limited)
upvote
share-icon
4 rounds | 10 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 10 months
Topics: Data Structures and Algorithms, OOPS, C programming, C++ Programming, Machine Learning, Operating System, Deep learning.
Tip
Tip

Tip 1 : Practice problems related to data structures and algorithms 
Tip 2 : Brush up fundamental concepts deeply
Tip 3 : You should have a deep knowledge of your projects and related technology.

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

Tip 1 : It should not be more than a page.
Tip 2 : It should be precise and university projects or prior experience like industrial training or internship should be mentioned.

Interview rounds

01
Round
Medium
Online Coding Interview
Duration60 minutes
Interview date16 Aug 2020
Coding problem3

It was held in the evening around 4 pm. The camera was on during the test to invigilate the activity of students. On any doubtful action, warning was given. Platform was easy to code in.

1. Replace 0s

Moderate
30m average time
70% success
0/80
Asked in companies
American ExpressPaytm (One97 Communications Limited)Amazon

Given a matrix where every element is either 1 or 0(zero), replace 0 with 1 if surrounded by 1. A 0 (or a set of 0s) is considered to be surrounded by 1 if there are 1 at locations just below, just above, just left and just right of it.

See the sample input.

Problem approach

I made some syntax errors in this one. Be careful.

Try solving now

2. Ways To Make Coin Change

Moderate
20m average time
80% success
0/80
Asked in companies
SamsungBNY MellonIBM

You are given an infinite supply of coins of each of denominations D = {D0, D1, D2, D3, ...... Dn-1}. You need to figure out the total number of ways W, in which you can make a change for value V using coins of denominations from D. Print 0, if a change isn't possible.

Problem approach

This was a greedy problem.
1. Sort the array of coins in decreasing order. Initialize result as empty.
2. Find the largest denomination that is smaller than current amount.
3. Add found denomination to result.
4. Subtract value of found denomination from amount.
5. If amount becomes 0, then print result.
6. Else repeat steps 3 and 4 for new value of V.

Try solving now

3. Partition a set into two subsets such that the difference of subset sums is minimum.

Hard
10m average time
85% success
0/120
Asked in companies
Goldman SachsSterlite Technologies LimitedAccenture

You are given an array 'arr' containing 'n' non-negative integers.


Your task is to partition this array into two subsets such that the absolute difference between subset sums is minimum.


You just need to find the minimum absolute difference considering any valid division of the array elements.


Note:

1. Each array element should belong to exactly one of the subsets.

2. Subsets need not always be contiguous.
For example, for the array : [1, 2, 3], some of the possible divisions are 
   a) {1,2} and {3}
   b) {1,3} and {2}.

3. Subset-sum is the sum of all the elements in that subset. 
Example:
Input: 'n' = 5, 'arr' = [3, 1, 5, 2, 8].

Ouput: 1

Explanation: We can partition the given array into {3, 1, 5} and {2, 8}. 
This will give us the minimum possible absolute difference i.e. (10 - 9 = 1).
Problem approach

The recursive approach is to generate all possible sums from all the values of the array and to check which solution is the most optimal one. 
To generate sums we either include the i’th item in set 1 or don’t include, i.e., include in set 2.
More optimized solution is Dynamic Programming.

Try solving now
02
Round
Medium
Face to Face
Duration60 minutes
Interview date18 Aug 2020
Coding problem4

It was held in the morning around 11:30 am. The interview was scheduled on google meet. The interviewer was quite friendly. He started by a brief introduction. This round was mostly based on Data structures and algorithms. At the end he asked some concepts of OOPs and Operating System.

1. String Transformation

Moderate
23m average time
0/80
Asked in companies
SprinklrWalmartAccenture

Given a string (STR) of length N, you have to create a new string by performing the following operation:

Take the smallest character from the first 'K' characters of STR, remove it from STR and append it to the new string.

You have to perform this operation until STR is empty.

 Note:
The input string(STR) will not contain any spaces.

Assume that all characters in STR are lower case letters.

If characters less than 'K' remain, then append them in a sorted way to the new string.
Example:
Let the input string be "edcba" with K = 4.

Let the new string to be formed is initially empty, newString = "".
The first set of 4 characters are, ('e', 'd', 'c', 'b')
Out of these 4 characters, the smallest one is 'b' and hence we add it to the newString and it becomes, 
newString = "b"

The next set of 4 characters are, ('e', 'd', 'c', 'a')
Out of these 4 characters, the smallest one is 'a' and hence we add it to the newString and it becomes, 
newString = "ba"

Now we are left with "edc" and since we can't get a window of size 4, we sort them in the increasing order and append them to the newString.

Hence, newString thus formed will be "bacde".
Problem approach

Solve string questions

Try solving now

2. Design a stack that supports getMin() in O(1) time and O(1) extra space

Moderate
15m average time
85% success
0/80
Asked in companies
ShareChatGrofersGroww

Create a stack data structure that allows operations such as push (adding an element), pop (removing the top element), top (retrieving the top element), and also provides a way to retrieve the minimum element in constant time.


Implement the following public functions :

1. push(data) :
This function should take one argument of type integer. It pushes the element into the stack and returns nothing.

2. pop() :
It pops the element from the top of the stack and returns nothing.

3. top() :
It returns the element being kept at the top of the stack.

4.  getMin() :
It returns the smallest element present in the stack.
Operations Performed on the Stack:
Query-1(Denoted by an integer 1): Pushes integer data to the stack. (push function)

Query-2(Denoted by an integer 2): Pops the data kept at the top of the stack. (pop function)

Query-3(Denoted by an integer 3): Fetches and returns the data being kept at the top of the stack. (top function)

Query-4(Denoted by an integer 4): Returns the smallest element present in the stack. (getMin() function)
Problem approach

1. Start from brute force approach by using another stack.
2. Optimise it with reducing push and pop operations.
3. Optimise it to O(1) space complexity.

Try solving now

3. Number of GP sequence

Moderate
10m average time
90% success
0/80
Asked in companies
HSBCPaytm (One97 Communications Limited)SAP Labs

You are given an array containing ‘N’ integers. You need to find the number of subsequences of length 3 which are in Geometric progression with common ratio ‘R’.

A geometric progression (GP), also called a geometric sequence, is a sequence of numbers that differ from each other by a common ratio. For example, the sequence 2,4,8,16,… is a geometric sequence with common ratio 2.

Note:
As the answer can be very large you need to return the answer in mod 10^9+7.
Problem approach

1. I started with brute force approach using three loops.
2. I optimized it to two loops by using sorting and two pointer technique.

Try solving now

4. Operating System

What are the conditions for a deadlock to occur?

Problem approach

Tip 1 : Explain what deadlock is briefly.
Tip 2 : Be confident while answering.
Tip 3 : Explain its conditions in detail. Refer to youtube channel gate smashers for clarity of topic.

03
Round
Medium
Face to Face
Duration45 minutes
Interview date18 Aug 2020
Coding problem2

It was held in the afternoon around 3pm. The interviewer was quite friendly. She started with my introduction. She asked 2-3 problems related to data structures and then asked about python libraries which I used in my projects.

1. Group Anagrams

Moderate
30m average time
70% success
0/80
Asked in companies
ThalesBarclaysAdobe

You have been given an array/list of strings 'inputStr'. You are supposed to return the strings as groups of anagrams such that strings belonging to a particular group are anagrams of one another.

An anagram is a word or phrase formed by rearranging the letters of a different word or phrase. We can generalize this in string processing by saying that an anagram of a string is another string with the same quantity of each character in it, in any order.

Note:
The order in which the groups and members of the groups are printed does not matter.
For example:
inputStr = {"eat","tea","tan","ate","nat","bat"}
Here {“tea”, “ate”,” eat”} and {“nat”, “tan”} are grouped as anagrams. Since there is no such string in “inputStr” which can be an anagram of “bat”, thus, “bat” will be the only member in its group.
Problem approach

I used hash maps to solve the problems.
 

Try solving now

2. Kth Smallest Element

Easy
15m average time
85% success
0/40
Asked in companies
Info Edge India (Naukri.com)Paytm (One97 Communications Limited)Media.net

You are given an array of integers 'ARR' of size 'N' and another integer 'K'.


Your task is to find and return 'K'th smallest value present in the array.


Note: All the elements in the array are distinct.


Example
If 'N' is 5 and 'K' is 3 and the array is 7, 2, 6, 1, 9

Sorting the array we get 1, 2, 6, 7, 9

Hence the 3rd smallest number is 6.
Problem approach

1. I started with brute force approach of sorting the array and then finding the kth smallest element. This was O(nlogn) approach.
2. Then I solved using heaps with an O(n) approach.

Try solving now
04
Round
Medium
Face to Face
Duration45 minutes
Interview date18 Aug 2020
Coding problem1

It was held in the evening around 6 pm. The interviewer started with a brief introduction of me. He asked about my projects and then asked some concepts of Operating System and problems related to data structures. I had projects of Machine Learning and Deep learning. Discussion about projects continued for about 25 minutes.

1. Middle of Linked List

Easy
20m average time
80% success
0/40
Asked in companies
NoBrokerSamsungCognizant

Given a singly linked list of 'N' nodes. The objective is to determine the middle node of a singly linked list. However, if the list has an even number of nodes, we return the second middle node.

Note:
1. If the list is empty, the function immediately returns None because there is no middle node to find.
2. If the list has only one node, then the only node in the list is trivially the middle node, and the function returns that node.
Problem approach

Used hare and tortoise method to solve this problem.

Try solving now

Here's your problem of the day

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

Skill covered: Programming

To make an AI less repetitive in a long paragraph, you should increase:

Choose another skill to practice
Similar interview experiences
company logo
Software Engineer
4 rounds | 9 problems
Interviewed by Paytm (One97 Communications Limited)
1457 views
0 comments
0 upvotes
company logo
Software Engineer
4 rounds | 8 problems
Interviewed by Paytm (One97 Communications Limited)
550 views
1 comments
0 upvotes
company logo
Software Engineer
4 rounds | 8 problems
Interviewed by Paytm (One97 Communications Limited)
459 views
0 comments
0 upvotes
company logo
Software Engineer
3 rounds | 6 problems
Interviewed by Paytm (One97 Communications Limited)
504 views
1 comments
0 upvotes
Companies with similar interview experiences
company logo
Software Engineer
3 rounds | 5 problems
Interviewed by Mindtree
12178 views
7 comments
0 upvotes
company logo
Software Engineer
3 rounds | 7 problems
Interviewed by Optum
7857 views
1 comments
0 upvotes
company logo
Software Engineer
5 rounds | 5 problems
Interviewed by Microsoft
9947 views
1 comments
0 upvotes