File Handling Flashcards

You may prefer our related Brainscape-certified flashcards:
1
Q

How to write to a file called name

A

names_file.write(x)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How to create and open a file called people

A

file = open(“people.txt”,”a”)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

How to close a file called names

A

names_file.close()

How well did you know this?
1
Not at all
2
3
4
5
Perfectly