139k views
1 vote
You are going to open a file in your program.

The program is saved in a folder, which has a subfolder called "textFiles."

In the textFiles folder is a text file called "books.txt."

Which line of code will open books.txt?


fileIn = open("textFiles/books.txt","r")
fileIn = open("textFiles/books.txt","r")

fileIn.open("textFiles/books.txt","r")
fileIn.open("textFiles/books.txt","r")

fileIn.open("books.txt","r")
fileIn.open("books.txt","r")

fileIn = open("books.txt","r")
fileIn = open("books.txt","r")

User Ran Hassid
by
5.3k points

1 Answer

0 votes

Answer:

fileIn = open("textFiles/books.txt","r")

Step-by-step explanation:

The code will open the file called books.txt, which is located in the textFiles folder.

User Marquette
by
5.7k points