A question on the creation of list of lists

Dave Angel davea at davea.name
Thu Apr 23 10:12:20 EDT 2015


On 04/23/2015 08:36 AM, Gregory Ewing wrote:
> Jean-Michel Pichavant wrote:
>>> From: "subhabrata banerji" <subhabrata.banerji at gmail.com>
>>>
>>> list_of_files = glob.glob('C:\Python27\*.*')
>  >
>> 1/ Your file pattern search will not get files that do not have any
>> dot in
>> their name
>
> Actually, on Windows, it will. (This is for compatibility with
> MS-DOS 8.3 filenames, where the dot wasn't actually stored, so
> there was no distinction between a filename with a dot and an
> empty extension, and a filename with no dot.)
>

That's certainly true at the command line in Windows DOS box, but I'd be 
astounded if glob used the same logic, even on Winodows.

-- 
DaveA



More information about the Python-list mailing list