Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import os
- from os.path import join
- inputdir = raw_input('Enter directory: ')
- fhand = open('results.txt', 'w')
- filedict = dict()
- for (dirname, dirs, files) in os.walk(inputdir):
- for filename in files:
- thefile = os.path.join(dirname, filename)
- fhand.write(thefile+'\n')
- fhand.close()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement