Pregunta de entrevista de Bank of America

How do you sort and array which million 0 and 1 one in a single pass.