0

What I'm trying to input is not working.

f = open("C:/Users/Jake/Desktop/Week10file.txt")
print(f.read())
f.write("University \n")

sjj
  • 1
  • 2
    You can't open a file for read and then write to it. If you want to write to a file, it needs to be open for write (or read/write, or append, etc). – Charles Duffy Nov 09 '22 at 22:49

0 Answers0