Perche' dovresti usare scandir per averli ordinati alfabeticamente.