I would like to print the final 13 lines of the csv file saved as updated_quotes
. It is returning a syntax error. How can I fix this?
import csv
from collections import deque
with open('updated_quotes', 'r') as csv_file:
csv_reader = csv.reader(csv_file)
def tail(csv_file, n=13):
'Return the last n lines of a file'
print(return deque(open(csv_file), n))