Skip to content

Problem 3356

Andrew Shepherd edited this page Nov 18, 2024 · 2 revisions

Problem 3356 - Zero Array Transformation II

LeetCode page

I originally solved this as a Segment Tree problem.

This turned out to be much simpler and faster using a priority queue.

Clone this wiki locally