+ 2
how to create text file in python?
im trying to make a function to create a file for a small program. not sure where im going wrong on creating the file enter file to save hashes in ifnot we will make it: 1 my error----> Traceback (most recent call last): File "C:\Users\mikey\Desktop\hash.py", line 7, in <module> f = open(hfile, 'wa') ValueError: Invalid mode ('wa') for some reason it worked earlier but not now?
3 Answers
+ 2
nvm yall i figured it out xD XD
look at my new codes???
run on pc not sololearn :P
https://code.sololearn.com/cC2nSFywJvbh/#py
https://code.sololearn.com/cWNLGpVoliwi/#py
+ 2
Are you sure that it was working before? I believe you can't use w and a in same time, since they do opposite things in terms of overriding.
+ 2
That second code tho, why are you still in Python2?