Problem 905 · Easy

Sort Array By Parity

Rearrange a list so every even value comes before every odd value. The visual sorts tiles into an even lane and an odd lane as two pointers move inward.

Open the interactive visualisation