# [Ruby], 23 bytes

<!-- language-all: lang-ruby -->

    ->a{a.sort_by{|i|~i%2}}

[Try it online!][TIO-jjqz1iia]

[Ruby]: https://www.ruby-lang.org/
[TIO-jjqz1iia]: https://tio.run/##LcjLCkBAFADQva@4jSzdsKP4EaQr1JRX81hM4/r1QVmdOsqOLix1SBvyhPpQZhidv@R1y6RgDgQ15Bkauc0aNzrBK9onSEvEkqPTGg1C7q8VQGdiTyz@VbO269vfLi31LMID "Ruby – Try It Online"