How can I obtain the expected result below?
import glob
infiles = glob.glob('E:\\test\\*.txt')
print infiles
['E:\\test\\a.txt', 'E:\\test\\b.txt', 'E:\\test\\c.txt', 'E:\\test\\d.txt']
Expected result is:
'E:\\test\\a.txt','E:\\test\\b.txt','E:\\test\\c.txt','E:\\test\\d.txt'
My attempt is:
infiles = ','.join(x for x in infiles)
print infiles
E:\test\a.txt,E:\test\b.txt,E:\test\c.txt,E:\test\d.txt