Hi all,
I'm trying to read a file (Python 2.5.2, Windows XP) as follows:
assignment_file = open('C:\Documents and Settings\coderoid\My
Documents\Downloads\code_sample.txt', 'r+').readlines()
new_file = open(new_file.txt, 'w+')
for line in assignment_file:
new_file.write(line)
new_file.close()
assignment_file.close()
When the code runs, the file path has the slashes converted to double
slashes. When try to escape them, i just seemto add more slashes. What am i
missing?
--
Regards,
Sithembewena Lloyd Dube
http://www.lloyddube.com
_______________________________________________
Tutor maillist - [email protected]
To unsubscribe or change subscription options:
http://mail.python.org/mailman/listinfo/tutor