Code360 powered by Coding Ninjas X Naukri.com. Code360 powered by Coding Ninjas X Naukri.com
Ernst & Young (EY) interview experience Real time questions & tips from candidates to crack your interview

SDE - 1

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

Interview preparation journey

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

Tip 1 : Practice coding questions daily
Tip 2 : Do good projects

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

Tip 1 : Do not lie on resume
Tip 2 : Have good projects on resume

Interview rounds

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

2 Coding Questions were asked. They were of medium level

1. Minimum and Maximum Cost to buy N Candies

Hard
10m average time
90% success
0/120
Asked in companies
Paytm (One97 Communications Limited)Tech MahindraGroww

Ram went to a specialty candy store in Ninjaland which has 'N' candies with different costs.

The Candy shop gives a special offer to its customers. A customer can buy a single candy from the store and get at most 'K' different candies for free. Now, Ram is interested in knowing the maximum and the minimum amount he needs to spend for buying all the candies available in the store.

Note: In both cases, Ram must utilize the offer i.e. if 'K' or more candies are available, he must take 'K' candies for every candy purchase. If less than K candies are available, he must take all candies for a candy purchase.

For Example :

For 'N' =  5 and 'K' = 2

Let the cost of different candies in the store be: [9 8 2 6 4]

For the minimum amount: 
Ram can buy a candy with cost 2 and take candies with costs 9 and 8 for free. 
Then, he can buy a candy with cost 4 and take candy with cost 7 for free. 
Thus, the minimum cost will be 6 i.e. 2 + 4. 

For the maximum amount: 
Ram can buy a candy with cost 9 and take candies with costs 2 and 6 for free. 
Then, he can buy candy at cost 8 and take candy at cost 4 for free. 
Thus, the minimum cost will be 17 i.e. 9 + 8.

Thus, Minimum = 6 and Maximum = 17.
Try solving now

2. Longest Consecutive Sequence

Moderate
40m average time
70% success
0/80
Asked in companies
AmazonGoogleApple

You are given an unsorted array/list 'ARR' of 'N' integers. Your task is to return the length of the longest consecutive sequence.

The consecutive sequence is in the form ['NUM', 'NUM' + 1, 'NUM' + 2, ..., 'NUM' + L] where 'NUM' is the starting integer of the sequence and 'L' + 1 is the length of the sequence.

Note:

If there are any duplicates in the given array we will count only one of them in the consecutive sequence.
For example-
For the given 'ARR' [9,5,4,9,10,10,6].

Output = 3
The longest consecutive sequence is [4,5,6].
Follow Up:
Can you solve this in O(N) time and O(N) space complexity?
Problem approach

This problem can be solved in O(n) time using an Efficient Solution. The idea is to use Hashing. We first insert all elements in a Set. Then check all the possible starts of consecutive subsequences.

Try solving now
02
Round
Easy
HR Round
Duration30 Minutes
Interview date22 Sep 2021
Coding problem1

It was like HR round

1. Basic HR Questions

Q1 Tell me about the projects you have done? 

Q2 Weaknesses and Strengths

 

Problem approach

Tip 1 : Be confident
Tip 2 : Communication skills should be good

Here's your problem of the day

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

Skill covered: Programming

Which of the following is not a Constraint in SQL?

Choose another skill to practice
Start a Discussion
Similar interview experiences
company logo
SDE - 1
3 rounds | 3 problems
Interviewed by Ernst & Young (EY)
1599 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 5 problems
Interviewed by Ernst & Young (EY)
778 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 5 problems
Interviewed by Ernst & Young (EY)
763 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 6 problems
Interviewed by Ernst & Young (EY)
1430 views
0 comments
0 upvotes
Companies with similar interview experiences
company logo
SDE - 1
1 rounds | 2 problems
Interviewed by Tata Consultancy Services (TCS)
0 views
0 comments
0 upvotes
company logo
SDE - 1
3 rounds | 4 problems
Interviewed by Tata Consultancy Services (TCS)
5724 views
0 comments
0 upvotes
company logo
SDE - 1
2 rounds | 3 problems
Interviewed by BNY Mellon
4967 views
3 comments
0 upvotes