J.P. Morgan Software Engineer Interview Experience — Two-Question OA on Array Simulation and Greedy

J.P. Morgan·Software Engineer·Oct 2026
Online Assessmentmedium

The OA had two coding questions in total. Overall difficulty was Easy to Medium, mainly testing Array Simulation and Greedy.

The specific questions:

Dropped Requests (Array Simulation): you are given an integer array. A positive integer means adding that many server threads, and -1 means a request comes in. Each request uses up one thread, and if there is no thread available the request is dropped. Return the total number of dropped requests. Just walk through the array and keep track of the current number of threads, O(n).

Maximum XOR (Greedy): you are given a binary string x, bits, and maxSet. You need to construct a binary string y that has at most maxSet ones and maximizes x XOR y. Go through the bits from the highest to the lowest, and prefer setting y to 1 at the positions where x is 0. O(n).

Published

Curated and edited by PracHub

Practice the questions from this interview

Discussion

Sign in to join the discussion. The author is notified of every comment.

Loading comments…

Interview at a glance

Company
J.P. Morgan
Role
Software Engineer
Rounds
Online Assessment
Difficulty
medium
Interview date
Oct 2026
Questions from this interview
2 questions

Real J.P. Morgan interview experiences

First-hand reports from J.P. Morgan candidates — the rounds, the questions they were asked, and how it went.

All 12 J.P. Morgan interview experiences