I have a script:
import csv
with open('2017020397.csv', newline='') as f:
reader = csv.reader(f)
for row in reader:
print(' '.join(row))
Output looks like this:
LastName StartTime EndTime Duration Period TeamAbbrev Pos
Bouwmeester 0:00 0:37 0:37 1 STL D
Schwartz 0:00 0:40 0:40 1 STL W
Foligno 0:00 0:40 0:40 1 MIN W
Pietrangelo 0:00 0:48 0:48 1 STL D
Suter 0:00 0:40 0:40 1 MIN D
Instead of printing the rows, I would like the rows to equal data. Then I can just say print(data)
. New to python and writing scripts.