Ernst & Young (EY) interview experience Real time questions & tips from candidates to crack your interview

SDE - 1

Ernst & Young (EY)
upvote
share-icon
3 rounds | 5 Coding problems

Interview preparation journey

expand-icon
Preparation
Duration: 3 months
Topics: Data Structures, Pointers, OOPS, System Design, Algorithms, Dynamic Programming
Tip
Tip

Tip 1 : Even if you are stuck in the problem, just give a try. The interviewer will help you definitely for sure.
Tip 2 : Prepare Data Structures and Algorithms well. They mostly check our Problem Solving ability to find the solutions for the real world problems.
Tip 3 : Be enough confident, don't be nervous. Maintain atleast 2 projects in your resume

Application process
Where: Campus
Eligibility: No criteria
Resume Tip
Resume tip

Tip 1 : Mention atleast 2 projects.
Tip 2 : Mention your skills in which you are perfect.
Tip 3 : It should not be too long or too short

Interview rounds

01
Round
Medium
Face to Face
Duration90 minutes
Interview date1 Nov 2022
Coding problem2

1. Maximum Sum

Moderate
35m average time
70% success
0/80
Asked in companies
GE (General Electric)DunzoAdobe

You are given an array “ARR” of N integers. You are required to perform an operation on the array each time until it becomes empty. The operation is to select an element from the array(let’s say at ith index i.e ARR[i]) and remove one occurrence of the selected element from the array and remove all the occurrences of (ARR[i]-1) and (ARR[i]+1) from the array(if present). Your task is to maximize the sum of selected elements from the array.

For example, let’s say the given array is [2, 3, 3, 3, 4, 5].

The maximum possible sum for the given array would be 14. Because if we select one of the 3’s from the array, then one 3 and all occurrences of (3-1) and (3+1) i.e 2 and 4 will be deleted from the array. Now we left with {3,3,5} elements in the array. Then again we select 3 in the next two steps and in both steps 3 will be deleted also (3-1) and (3+1) doesn't exist in the array so nothing extra to delete in both steps. Now we left with only {5} and in the next step, we select the 5 and delete it. Then the array becomes empty. Thus the sum of selected elements will be 3+3+3+5 = 14.

Problem approach

Dynamic Programming
s1= The idea is to use a bottom-up dynamic programming approach instead of a memoization approach. In this, we also have two choices whether to select or not. 
a2- If we select then we take the occurrences of that number and the value stored at dp[i-2] as dp[i-1] will be deleted and not be taken to count. If we do not select the number then we take dp[i-1] which have been already calculated.

Try solving now

2. Rearrange The Array

Moderate
15m average time
90% success
0/80
Asked in companies
Thought WorksOracleOla

You are given an array/list 'NUM' of integers. You are supposed to rearrange the elements of the given 'NUM' so that after rearranging the given array/list there are no two adjacent elements present in the rearranged 'NUM' which will be the same.

For example:
Input: NUM[] = {1,1,1,2,2,2} 
Output: {1,2,1,2,1,2}
Note: {2,1,2,1,2,1} is also valid because there are no two adjacent which are the same.
Problem approach

s1- line contains an integer 'T' which denotes the number of test cases or queries to be run. 
s2- Greedy with priority queue

Try solving now
02
Round
Easy
Face to Face
Duration30 Minutes
Interview date8 Nov 2022
Coding problem2

1. Yogesh And Primes

Moderate
20m average time
0/80
Asked in companies
OracleErnst & Young (EY)Capegemini Consulting India Private Limited

Yogesh is a very intelligent student and is interested in research in Machine Learning domain. His college has only one professor, Mr. Peter working in that field. He approaches the professor for the same, but professor wants to test him first.

To pass the test Yogesh must answer Q questions correctly. In all the Q questions, professor gives him three positive integers : A, B and K where A ≤ B.

Now Yogesh has to find an integer P such that it is closest to integer A and there are at least K prime numbers in range [A, P], where A <= P <= B.

Help Yogesh to find and print minimum possible P or print -1 if there no such possible integer.

Note: A prime number is a natural number greater than 1 that has no positive divisors other than 1 and itself.

Try solving now

2. Reverse Words In A String

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

You are given a string 'str' of length 'N'.


Your task is to reverse the original string word by word.


There can be multiple spaces between two words and there can be leading or trailing spaces but in the output reversed string you need to put a single space between two words, and your reversed string should not contain leading or trailing spaces.


Example :
If the given input string is "Welcome to Coding Ninjas", then you should return "Ninjas Coding to Welcome" as the reversed string has only a single space between two words and there is no leading or trailing space.
Try solving now
03
Round
Easy
Video Call
Duration30 Minutes
Interview date10 Nov 2022
Coding problem1

1. Product Of Array Except Self

Easy
26m average time
0/40
Asked in companies
IntuitQualcommFacebook

You have been given an integer array/list (ARR) of size N. You have to return an array/list PRODUCT such that PRODUCT[i] is equal to the product of all the elements of ARR except ARR[i]

 Note :
Each product can cross the integer limits, so we should take modulo of the operation. 

Take MOD = 10^9 + 7 to always stay in the limits.
Follow up :
Can you try solving the problem in O(1) space?
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

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

Choose another skill to practice
Similar interview experiences
company logo
SDE - 1
3 rounds | 3 problems
Interviewed by Ernst & Young (EY)
2674 views
0 comments
0 upvotes
company logo
SDE - 1
2 rounds | 3 problems
Interviewed by Ernst & Young (EY)
1792 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 5 problems
Interviewed by Ernst & Young (EY)
1250 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 6 problems
Interviewed by Ernst & Young (EY)
2507 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
SDE - 1
2 rounds | 3 problems
Interviewed by BNY Mellon
6365 views
3 comments
0 upvotes
company logo
SDE - 1
3 rounds | 6 problems
Interviewed by BNY Mellon
0 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 5 problems
Interviewed by CIS - Cyber Infrastructure
2197 views
0 comments
0 upvotes