### QUESTION FIVE ### def select_lines_from_file(filename, query): pass


### QUESTION FIVE ###<br>def select_lines_from_file(filename, query):<br>pass<br>

Extracted text: ### QUESTION FIVE ### def select_lines_from_file(filename, query): pass
5. select_lines_from_file<br>In this function, we will open a file for reading, look at each line in the file, and return a list of the lines in the file that<br>contain a specified query string. We do not need to change the lines in the file in any way, just put them in a list and<br>return that list. Don't worry about case<br>this function is case-insensitive.<br>If we have the following text in a file called final_sample.txt:<br>it was the best of times<br>it was the worst of times<br>time keeps on slippin into the future<br>this sentence does not contain that particular word<br>also this one doesn't contain it either<br>

Extracted text: 5. select_lines_from_file In this function, we will open a file for reading, look at each line in the file, and return a list of the lines in the file that contain a specified query string. We do not need to change the lines in the file in any way, just put them in a list and return that list. Don't worry about case this function is case-insensitive. If we have the following text in a file called final_sample.txt: it was the best of times it was the worst of times time keeps on slippin into the future this sentence does not contain that particular word also this one doesn't contain it either

Jun 11, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here