MEDIUMasked at 1 company

Maximum Profit of Operating a Centennial Wheel

A medium-tier problem at 44% community acceptance, tagged with Array, Simulation. Reported in interviews at peak6 and 0 others.

Founder's read

You get a wheel with buckets that rotate every minute. You can buy tickets, board passengers, and sell them off at any point. The trick is figuring out when to lock in profit versus wait for the next rotation. It's a simulation problem wrapped in an optimization puzzle. Peak6 has asked it. With a 44% acceptance rate, most people either miss the state-tracking or blow up their loop logic. You need to track passenger count, money, and rotation cycles without losing your head to off-by-one errors.

Companies asking
1
Difficulty
MEDIUM
Acceptance
44%

Companies that ask "Maximum Profit of Operating a Centennial Wheel"

If this hits your live OA

Maximum Profit of Operating a Centennial Wheel 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. Built by an engineer at a top-10 tech company who can solve these problems cold but didn't want to trust himself in a 90-minute screen share.

Get StealthCoder
What this means

The pattern here is straightforward simulation, but the devil lives in the details. You iterate through rotations: each minute, passengers board (capped by remaining capacity), the wheel rotates, you sell some or all passengers, and you bank profit. The catch is that you can only sell when the wheel completes a full rotation and returns to its boarding position. You're tracking the current bucket fill, total revenue, and cycles. The common trap is conflating bucket index with rotation count, or forgetting that the wheel position matters for when sales happen. If you hardcode the wrong condition for when you can sell, your profit tanks. StealthCoder is the safety net if your sim collapses at test time on this specific problem.

Pattern tags

The honest play

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

Maximum Profit of Operating a Centennial Wheel 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. Built by an engineer at a top-10 tech company who can solve these problems cold but didn't want to trust himself in a 90-minute screen share. Works on HackerRank, CodeSignal, CoderPad, and Karat.

Maximum Profit of Operating a Centennial Wheel interview FAQ

Is this problem actually testing simulation, or is there a greedy trick?+

Pure simulation. There's no closed-form formula. You iterate through rotations and decide at each step whether to sell. Greedy heuristics fail because profit depends on passenger load and ride duration. You need to simulate all valid scenarios and track the max.

What's the main way people fail this at Peak6 interviews?+

Off-by-one errors in rotation counting and confusion about when the wheel is at the boarding position. People also forget that you can't sell mid-rotation, or they conflate bucket index with ride cycle. Trace through a small example by hand first.

Does bucket capacity matter, or is it just a cap on boarding?+

It's a hard cap. Each rotation, you board min(waiting passengers, remaining bucket capacity) people. If your bucket is full, nobody else boards that rotation. This directly impacts profit timing, so track it carefully.

Why is the acceptance rate only 44% for a medium simulation problem?+

State management is tricky. You're tracking multiple variables (bucket fill, money, rotation count, customer queue) and must nail the loop conditions. One wrong boundary and your answer is off. It looks easy until you test.

Is this problem more math or code?+

Mostly code. It's a state machine. The math is basic multiplication. The hard part is getting the loop, conditions, and variable updates right without losing track of which step you're on.

Want the actual problem statement? View "Maximum Profit of Operating a Centennial Wheel" 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.