fileinput.input, readlines and ...

Kushal Kumaran kushal.kumaran+python at gmail.com
Fri Jun 26 09:47:37 CEST 2009


On Thu, Jun 25, 2009 at 10:32 AM, Private Private<mail131 at gmail.com> wrote:
> On Jun 24, 12:23 pm, Przemyslaw Bak <mail... at gmail.com> wrote:
>> Hello,
>>
>> I many files with log data. The structure of the file is quite
>
> Each requested value is in separated file.
> While traversing using os.path.walk I have noticed that I get files
> unsorted.
> Is it possible to get them sorted ?
>

You can use the os.walk generator and sort the filenames in the returned tuple.

-- 
regards,
kushal



More information about the Python-list mailing list