Partition Array by Odd and Even
Partition an integers array into odd number first and even number second.
Example
Given[1, 2, 3, 4]
, return[1, 3, 2, 4]
分析
对撞指针,quick select,不必递归
答案
Last updated
Partition an integers array into odd number first and even number second.
Example
Given[1, 2, 3, 4]
, return[1, 3, 2, 4]
分析
对撞指针,quick select,不必递归
答案
Last updated