The TransCompilator

Solved LeetCode program · 673 of 1,000

#0905 · Sort Array By Parity

Easy Array chunk-14.md

Original English source

The numbers is a list of 3, 1, 2, and 4. The ordered is an empty list of whole numbers.
For each value in numbers.
If value modulo 2 is 0, Place value into ordered.

For each value in numbers.
If value modulo 2 is not 0, Place value into ordered.

For each value in ordered, show value.

Open in Playground Browse all 1,000 problems

Expected stdout

2
4
3
1