MEDIUMasked at 2 companies

Minimum Limit of Balls in a Bag

A medium-tier problem at 67% community acceptance, tagged with Array, Binary Search. Reported in interviews at Flipkart and 1 others.

Founder's read

You're looking at a problem that hits the intersection of Array and Binary Search, two fundamentals that most candidates think they know cold until they see it framed this way. Flipkart and Intuit have both asked it. The acceptance rate sits around 67%, which means a third of people who attempt it walk away stuck. The trick isn't in the array itself. It's recognizing that you're not searching the array directly, you're binary searching over a range of possible answers. That pattern flip is what separates people who solve it clean from people who thrash. If you blank on it during the live assessment, StealthCoder surfaces a working solution in seconds, invisible to the proctor.

Companies asking
2
Difficulty
MEDIUM
Acceptance
67%

Companies that ask "Minimum Limit of Balls in a Bag"

If this hits your live OA

Minimum Limit of Balls in a Bag is the kind of problem that decides whether you pass. StealthCoder reads the problem on screen and surfaces a working solution in under 2 seconds. Invisible to screen share. The proctor sees nothing. Made by a working Amazon engineer who got tired of watching qualified friends bomb OAs they'd solve cold in an IDE.

Get StealthCoder
What this means

The problem forces you to think backward. Instead of iterating through the array to find an answer, you set bounds on what the answer could be and binary search within that space. Most candidates start by trying to directly manipulate the array or compute a single value, which collapses immediately when the constraint tightens. The real pattern: define a search range (min to max possible value), then for each candidate answer, check if it's valid by running a simulation or check against the array. The binary search narrows down to the optimal value. The common miss is not recognizing the problem statement is asking you to minimize something, which signals that binary search on the answer space is the move. When you hit this during an online assessment, it's the kind of problem where the first hour can evaporate if you're not solid on answer-space binary search. StealthCoder's the hedge for the moment you realize the greedy approach or brute force won't scale.

Pattern tags

The honest play

You know the problem. Make sure you actually pass it.

Minimum Limit of Balls in a Bag recycles across companies for a reason. It's medium-tier, and most candidates blank under the timer. StealthCoder is the hedge: an AI overlay invisible during screen share. It reads the problem and surfaces a working solution in under 2 seconds. Made by a working Amazon engineer who got tired of watching qualified friends bomb OAs they'd solve cold in an IDE. Works on HackerRank, CodeSignal, CoderPad, and Karat.

Minimum Limit of Balls in a Bag interview FAQ

Is this problem actually asked at Flipkart and Intuit?+

Yes, both companies are in the reported data for this problem. It's not a rare edge case. If you're interviewing there, especially for mid-level or above roles that touch optimization, this pattern shows up.

Why is the acceptance rate 67% if it's a medium?+

Because most people don't recognize it's a binary search problem. They see array and think linear iteration or sorting. Once you know the pattern, it's straightforward. That 33% failure rate is pattern recognition, not algorithmic complexity.

Do I need to know both Array and Binary Search equally well?+

Binary Search is the core skill here. Array fundamentals matter only for the simulation or validation step. If you're weak on binary search on answer spaces, you'll struggle. If you're solid there, the array part is secondary.

How long should I spend on this if I blank during the OA?+

If you don't see the binary search angle within 10-15 minutes, you're likely going to lose 45 minutes thrashing. That's when you need the solution surfaced fast. StealthCoder's invisible nature means you get the working code without raising red flags.

Is this problem still relevant or has it aged out of interviews?+

Recent reports show Flipkart and Intuit both asking it. It's not a legacy problem. The pattern (binary search on answer space) is core to optimization problems across tech, so mastering it pays dividends beyond this single problem.

Want the actual problem statement? View "Minimum Limit of Balls in a Bag" on LeetCode →

Frequency and company-tag data sourced from public community-maintained interview-report repos. Problem, description, and trademark © LeetCode. StealthCoder is not affiliated with LeetCode.