Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #102146
| From | Gary Roach <gary719_list1@verizon.net> |
|---|---|
| Newsgroups | comp.lang.python |
| Subject | Duplicate Output |
| Date | 2016-01-26 10:48 -0800 |
| Message-ID | <mailman.28.1453883934.2338.python-list@python.org> (permalink) |
Hi
Debian stretch OS
KDE Desktop
Code written with Kate
Run in command line with $python getFileNames.py
Code:
from os import walk
import subprocess
f = []
x = ""
for (dirpath, dirnames, filenames) in walk('.'):
print(filenames)
This prints [<file list>][<duplicate file list>]
What am I doing wrong or how do I remove the duplicate list.
Gary R.
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Duplicate Output Gary Roach <gary719_list1@verizon.net> - 2016-01-26 10:48 -0800
csiph-web