Pregunta de entrevista de Anonymous

Sort the given array in a two dimensional form