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

SDE - 2

PayPal
upvote
share-icon
4 rounds | 6 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 2 months
Topics: Data Structures, Algorithms, AWS, HDD and LDD, Spring Framework, Java
Tip
Tip

Tip 1 : DS should be strong practice coding on online portals.
Tip 2 : Clean and optimized code writing skills which can be achieved by daily code practice on Leetcode, CodeStudio etc
Tip 3 : Practical Knowledge which we can get from real project implementation

Application process
Where: Other
Eligibility: No Criteria
Resume Tip
Resume tip

Tip 1 : Data should be true and aligned to the role you are applying
Tip 2 : Have some projects

Interview rounds

01
Round
Medium
Online Coding Test
Duration60 minutes
Interview date13 Sep 2021
Coding problem2

The Test Link was shared by HR and it had an expiry of 2 days so we had to complete the test any time within 2 days. 2 questions were there in that test one was easy and one was a  bit on the harder side. However, we had enough time to complete those questions.

1. Good Number

Moderate
0/80
Asked in companies
ApplePayPalAdobe

You are given an integer ‘N’, you need to find whether it’s a good number or not.

We start from the integer ‘N’ and keep replacing the current number with the sum of squares of its digits, we keep repeating this process until we will the number 1. A number that generates the 1 after finite repetition of the above process is called a good number.

Example :
If ‘N’ = 7,

Then we start with the integer 7 and replace it with (7 * 7) = 49.
The new number is 49, we replace it with (4 * 4) + (9 * 9) = 97.
We replace this new number 97 with (9 * 9) + (7 * 7) = 130.
We replace this new number 130 with (1 * 1) + (3 * 3) + (0 * 0) = 10.
We replace this new number 10 with (1 * 1) + (0 * 0) = 1.

Therefore, the original number 7 is a good number. 
Problem approach

With of help of recursion and replacement of number to squares of its number. Some of the test cases I was able to pass.

Try solving now

2. Minimum Cost To Connect Sticks

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

You are given an array/list ‘ARR’ of ‘N’ positive integers where each element describes the length of the stick. You have to connect all sticks into one. At a time, you can join any two sticks by paying a cost of ‘X’ and ‘Y’ where ‘X’ is the length of the first stick and ‘Y’ is the length of the second stick and the new stick we get will have a length equal to (X+Y). You have to find the minimum cost to connect all the sticks into one.

Problem approach

Solved using Priority Queue

Try solving now
02
Round
Medium
Video Call
Duration60 minutes
Interview date18 Sep 2021
Coding problem1

DS Algo Coding Questions - First we need to discuss our optimized approach and write code for the same.
2 questions were asked,

1. Pair Sum in BST

Easy
15m average time
85% success
0/40
Asked in companies
HikeDunzoPayPal

You are given a Binary Search Tree (BST) and a target value ‘K’. Your task is to return true if there exist two nodes in the given BST such that the sum of their values is equal to the given target ‘K’, else return false.


A binary search tree (BST) is a binary tree data structure which has the following properties.

• The left subtree of a node contains only nodes with data less than the node’s data.

• The right subtree of a node contains only nodes with data greater than the node’s data.

• Both the left and right subtrees must also be binary search trees.


Note:
1. All the elements of the Binary Search Tree are unique.

2. You can’t use the same node value/element of BST twice.


For example:
tree: 8 5 10 2 6 -1 -1 -1 -1 -1 7 -1 -1
'K' = 13,

The nodes with values 8 and 5 as shown in the above figure gives sum equal to the given target 13. 

Therefore, the output will be “true” i.e it is possible to find a pair in the given BST having sum equal to ‘K’.
Problem approach

With the help of HashMap or with Set I was able to solve this question.
Put the targetSum-nodeValue in the Set and check on every iteration of that node if it is present in the Set or Map. Then yes target sum is present. 
Space and Time Complexity - O(n)

Try solving now
03
Round
Easy
Video Call
Duration60 minutes
Interview date18 Mar 2022
Coding problem2

It was a combination of System Design and Problem Solving.

1. Maximum Frequency Number

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

Ninja is given an array of integers that contain numbers in random order. He needs to write a program to find and return the number which occurs the maximum times in the given input. He needs your help to solve this problem.

If two or more elements contend for the maximum frequency, return the element which occurs in the array first i.e. whose index is lowest.

For example,

For 'arr' = [ 1, 2, 3, 1, 2]. you need to return 1.
Problem approach

With the help of HashMap and iteration, we can solve this question.
 

Try solving now

2. System Design Question

Design Library Management System

Problem approach

Tip 1 : Listen to the requirements of the interviewer (features)
Tip 2 : Design a Database with proper primary and foreign keys
Tip 3 : Design APIs with proper request and response. What all queries will be triggered in that API and it should represent proper explanation for monitoring of microservices( if opting for it what all services were made and use of it) and which DB are we going to use and why.

04
Round
Easy
HR Round
Duration30 minutes
Interview date18 Mar 2022
Coding problem1

This was a Technical Cum HR round where I was first asked some basic OOPS related concepts and then we discussed about my expectations from the company, learnings and growth in the forthcoming years. I would suggest be honest and try to communicate your thoughts properly in these types of rounds to maximise your chances of getting selected.

1. Basic HR Question

Why should we hire you?

Problem approach

Tip 1 : The cross-questioning can go intense sometimes, think before you speak.


Tip 2 : Be open-minded and answer whatever you are thinking, in these rounds, I feel it is important to have an opinion.
 

Tip 3 : The context of questions can be switched, pay attention to the details. It is okay to ask questions in these rounds, like what are the projects currently the company is investing in, which team you are mentoring, how is the work environment etc.

Here's your problem of the day

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

Skill covered: Programming

How do you remove whitespace from the start of a string?

Choose another skill to practice
Similar interview experiences
company logo
SDE - 2
4 rounds | 6 problems
Interviewed by PayPal
1816 views
0 comments
0 upvotes
company logo
SDE - 2
5 rounds | 6 problems
Interviewed by PayPal
8870 views
0 comments
0 upvotes
company logo
SDE - 2
5 rounds | 9 problems
Interviewed by PayPal
2812 views
0 comments
0 upvotes
company logo
SDE - 2
2 rounds | 4 problems
Interviewed by PayPal
1002 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
SDE - 2
5 rounds | 12 problems
Interviewed by Walmart
29891 views
8 comments
0 upvotes
company logo
SDE - 2
3 rounds | 5 problems
Interviewed by Amazon
6765 views
1 comments
0 upvotes
company logo
SDE - 2
6 rounds | 8 problems
Interviewed by Amazon
5280 views
0 comments
0 upvotes