ended3월 22일· 4 sources
Task – Move All Negative Elements to the End (Maintain Order)
음수 원소를 배열 끝으로 이동시키기 (순서 유지)
Why it matters
The task requires moving all negative elements in an unsorted array to the end while preserving the relative order of both positive and negative elements. The approach uses two auxiliary lists to separately collect positives and negatives, then overwrites the original array with positives first followed by negatives, achieving O(n) time and O(n) space complexity.
4
Sources
+0
24h
—
Growth
183d
Active
array manipulationarray rearrangementarray reorderingin-placein-place segregationin-place swapnegative elementsorder preservationpythonstable partition