In code(pseudo) like this
def path():
dirList = ['c:\\', 'y:\\', 'z:\\']
home_folder = 'peter.txt'
complete = [s + home_folder for s in dirList]
print complete
def fileWrite():
filename = 'c:\peter.txt'
text = 'Hello World'
file = open(filename, 'w')
file.write(text)
file.close()
I can make both work. I want all the items from the first to be iterated and run in the second. I am not entirely sure how to do that. Any help, much appreciated.