Reported July 2026
DE Shawmath

Minimum Frames for Equal Chunks

Reported by candidates from DE Shaw's online assessment. Pattern, common pitfall, and the honest play if you blank under the timer.

Get StealthCoderRuns invisibly during the live DE Shaw OA. Under 2s to a working solution.
Founder's read

DE Shaw reported this one in July 2026, and the input size is the first thing to check. You get an array of dataframe sizes, and each one has to end up splittable into at least two equal positive chunks. You can only add frames. Brute force per element is fine here because each value is handled on its own. The wording is dressy, but the core is a parity check in disguise. If you blank on the reading, StealthCoder can run invisibly during the live OA as a safety net, but this one is short enough to solve cold.

The problem

You are given an array dataframes of positive integers. Each value represents the size of one dataframe.
For every dataframe, its final size must be divisible into at least two chunks of equal positive size. You may add frames to a dataframe. Return the minimum total number of frames that must be added across all dataframes.
The source sample shows that values already divisible into two equal chunks need no extra frames, while 1 and 5 each need one added frame.

Function
minimumFramesForEqualChunks(dataframes: int[]) → int

Examples
Example 1
dataframes = [1,6,8,2,5]
return = 2
6, 8, and 2 can already be divided into two equal chunks. Add one frame to 1 and one frame to 5, so the answer is 2.

Reported by candidates. Source: FastPrep

Pattern and pitfall

Read it twice. Splitting into at least two equal chunks of positive size means the total has k chunks of size c with k >= 2. Chunk size 1 is allowed, so any value n >= 2 already works as n chunks of size 1. That means only n = 1 is a problem. The example looks like it says 5 needs a frame, which would mean 6 beats 5, so the intended rule seems to be exactly two equal chunks, meaning even sizes. Under that reading, each odd value costs one frame and the answer is the count of odd numbers. Example: [1,6,8,2,5] has two odds, so 2. The pitfall is overthinking it with divisors or primes. Confirm against the sample before you code: 5 needing a frame settles it. Then it's one pass, O(n) time, O(1) space. If the sample confuses you under pressure, StealthCoder is the hedge in the live OA.

The honest play: practice the pattern, and have StealthCoder ready for the one you didn't see coming.

If this hits your live OA

You can drill Minimum Frames for Equal Chunks cold, or you can hedge it. StealthCoder runs invisibly during screen share and surfaces a working solution in under 2 seconds. The proctor sees the IDE. They don't see what's behind it. Built for the candidate who saw this exact problem leak two days before his OA and wondered if anyone had a play.

Get StealthCoder

Related leaked OAs

⏵ The honest play

You've seen the question. Make sure you actually pass DE Shaw's OA.

DE Shaw reuses patterns across OAs. Built for the candidate who saw this exact problem leak two days before his OA and wondered if anyone had a play. Works on HackerRank, CodeSignal, CoderPad, and Karat.

Minimum Frames for Equal Chunks FAQ

What's the trick in Minimum Frames for Equal Chunks?+

Use the sample to decode the rule. Values 6, 8 and 2 need nothing, while 1 and 5 each need one frame. That matches 'splittable into two equal chunks', which means even. Each odd number costs exactly one added frame, because adding one makes it even.

How hard is this DE Shaw question really?+

Easy to code, easy to misread. The implementation is a single loop counting odd values. The risk is overcomplicating it with divisor or prime logic. Check your interpretation against the given example before writing anything.

What's the time complexity I should aim for?+

O(n) time and O(1) extra space. Each dataframe is independent, so one pass is enough. You don't need sorting, hashing, or any data structure. Anything slower than linear means you're solving a harder problem than the one asked.

Why does the answer for [1,6,8,2,5] equal 2?+

6, 8 and 2 are even, so each splits into two equal chunks already. 1 and 5 are odd, so each needs one more frame to become 2 and 6. Two additions total. That example is the cleanest way to confirm the rule.

How do I prepare for this in 48 hours?+

Don't grind it. Practice reading problem statements and testing your interpretation against the sample. Write the odd-count solution, then test edge cases: a single element, all even, all odd, and large values. Aim for a clean solution in under ten minutes.

Problem reported by candidates from a real Online Assessment. Sourced from a publicly-available candidate-aggregated repository. Not affiliated with DE Shaw.

OA at DE Shaw?
Invisible during screen share
Get it