JP Morgan|Associate|Mumbai|Sep2021
Summary
I went through a four-round interview process with JP Morgan for an Associate position in Mumbai, primarily focusing on C++ OOPs concepts, data structures, algorithms, and behavioral questions. Each round involved in-depth discussions and coding challenges, some with provided LeetCode links and others as custom problem statements.
Full Experience
Round 1 - 60 minutes phone call
My first round was a 60-minute phone call. We had a detailed discussion on several core OOPs concepts including special pointers, virtual tables, const functions, private constructors, and the Singleton pattern. Following this, I was given one coding question and one behavioral question.
Round 2 - 60 minutes screen sharing
The second round involved 60 minutes of screen sharing. We continued our discussion on OOPs concepts, delving into special pointers, the const keyword, inline functions, how virtual functions are implemented (vtable), how the vtable of base and derived classes would look for a function override, and virtual destructors. After the discussion, I was given another coding question.
Round 3 - 60 minutes screen sharing
My third round, also 60 minutes with screen sharing, started with a discussion on OOPs concepts in the context of a trade system, specifically inheritance. I was then asked a design question about creating a stack class by inheriting from an array class, its pros/cons, and alternative implementations. Further OOPs concepts like metaclasses, composition, encapsulation, and inheritance were discussed. This round concluded with two coding questions.
Round 4 - 30 minutes screen sharing
The final round was a 30-minute screen sharing session. I was presented with one coding question, followed by two behavioral questions, one of which was a repeat from the first round.
Interview Questions (12)
I discussed various OOPs concepts including special pointers, virtual tables, const functions, private constructors, and the Singleton pattern.
I was asked about my motivations for wanting to join the Quantitative Research (QR) profile.
I had a discussion on special pointers, the const keyword, inline functions, virtual function implementation including vtables, how vtables look for base and derived classes with function overrides, and virtual destructors.
We discussed OOPs concepts related to a trade system, specifically focusing on inheritance.
I was asked about the pros and cons of creating a stack class by inheriting from an array class, and if there are other ways to implement a stack.
I had a discussion covering metaclasses, composition, encapsulation, and inheritance.
A frog is on a number line starting at 0. It can take either 2 or 3 hops at once. I needed to find the probability of the frog reaching a specific number n from 0.
I was given a list of jobs <Ji>, each with a deadline <Ti> and an associated profit <Pi>. Each job takes 1 hour to complete. The task was to return a list of k jobs to generate the maximum profit within a given deadline n and profit value.
An example was provided:
Jobs:
j1 - deadline 3 - profit 50
j2 - deadline 2 - profit 200
j3 - deadline 1 - profit 30
j4 - deadline 1 - profit 20
j5 - deadline 2 - profit 150
If k=3, the maximum profit is 400 (j2+j5+j1).
Hints provided were:
1. Sort based on profit.
2. Use a bucket of size n (Bucket[n]) and fill it such that at index k, put profit for which deadline is k. If that place is filled, try the previous location.
I was asked if I had any issues with relocation.