Coding Round – 90 minutes – Hackerrank
Problem 1 : Given an array of N integers. Find number of sub-arrays with M number of odd integers.
Problem 2 : N gears were given each with their own cost ci and radius ri. One extra gear was also given with radius r1. A distance d was given and we had to find the gear with minimum cost following the below conditions:-
- ri +r1>=d(if there are multiple gears satisfying this condition then see condition 2 for those set of gears satisfying condition 1)
- Minimum cost ci(if there are multiple gears satisfying this condition then see condition 3 for those set of gears satisfying condition 1 & 2)
- Find the gear with larger radius(if there are multiple gears satisfying this condition then see condition 4 for those set of gears satisfying condition 1 & 2 & 3)
- Choose the gear with smaller index.
Problem 3 : Graph problem Based on Union find.
Can be done without union find also.
There is a city with n areas, and we need to build clinics in the city such that all the areas have access to the clinics.
The road between the cities might be damaged or broken.
The cost for repairing the road is R and the cost of building the clinic is C.
Find the minimum cost such that all the areas have access to at least one clinic.
For example( If the city is divided into three areas such that the roads between those areas are damaged that either we can build the clinics in all three areas or build the clinic in any one area and connect the other two areas with it by repairing the roads between them.)
Round 2: This was a Face-to-Face interview round.
Problem 1 : Base on bipartite matching.
Given a certain no. of prisoners. Where prisoner ai is enemy of prisoner aj we need to find that whether it’s possible to divide the prisoners into two cells equally such that the constraints are also satisfied.
Problem 2 : Given a path there are some nodes landing on which stops further movement. So if a monkey wants to reach the end of the path find the total no. of ways he can do it. I said that an easy approach would be recursion which he agreed. Then immediately went onto explaining the DP approach. He seemed satisfied.
Round 3: Face-to-face round
Problem 1 : They repeated the problem 1 from round 2 with some modification. I said that I had already discussed this in the previous round (extra points for honesty I guess :p). So the next problem was given an array of temples with certain heights, U need to find the total offering u need to do such that at each temple the offering is more than whatever is offered to any of the temples with a lower height. I said simple sorting works in this case. So the question was modified now where the offering only depends on the adjacent temples.
Problem 2: Given a binary tree suppose I start the fire at a leaf node, what is the total time for all the nodes to get burned.
Round 4: This was HM + Technical Round
Given a wall, u have some portraits. u place portraits on the wall randomly. Overlap, leaving space everything possible. So now at the end of all assignment find the total no. of portraits visible.
Had a detailed discussion about my internship and other projects. Other than that hr questions where covered too.
This round lasted up to an hour or so.
Round 5 : Hr round.
As soon as entered the room they shook my hand and said welcome to Flipkart. Then explained about my role in the company
Suggestions: We know it’s very obvious but we never follow it but still keep very calm, remember where u are in a search of a job even the recruiter is in search of a good candidate. Also, after each round ask questions and use them to ur benefit in the next round.
I would like to thank GeeksforGeeks + interviewbit for helping me in my preparation and would suggest u the same.
- MathWorks Interview Experience (EDG, Oncampus)
- ServiceNow Interview Experience Oncampus
- UHG Interview Experience | OnCampus- 2019
- InfoEdge Interview Experience | OnCampus-2019
- Amazon Interview Experience | Set 185 (For SDE1)
- Amazon interview Experience | Set 141 (For SDE1)
- Amazon Interview Experience | Set 150 (SDE1 for 1 Year Experienced)
- Amazon Interview Experience | Set 153 (For SDE1)
- Bharti SoftBank (Hike) Interview Experience | Set 4 (Off-Campus for SDE1)
- Microsoft Interview Experience | Set 42 (For SDE1)
- Amazon Interview Experience | Set 184 (Off Campus for SDE1)
- Amazon Interview Experience | Set 186 (For SDE1)
- Amazon Interview Experience | Set 187 (For SDE1)
- Amazon Interview Experience | Set 188 (For SDE1)
- Amazon Interview Experience | Set 213 (Off-Campus for SDE1)
- Expedia Interview Experience | Set 7 (4.5 Years Experienced for SDE1)
- Amazon Interview Experience | Set 254 (Off-Campus for SDE1)
- Amazon Interview Experience | Set 256 (Written Test for SDE1)
- Amazon Interview Experience | Set 258 (For SDE1)
- Amazon Interview Experience | Set 259 (1 Yr Experienced for SDE1)
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.