wordList = ["Red", "Blue", "Green"] filePath = "output.txt" file = open(filePath, 'wU') file.writelines(wordList) file.close()