BlueStone interview question

sort array having 0, 1, 2