이제 데이터가 잘 정제되었는지 확인해 볼까요?
import csv f = open('subwayfee.csv') data = csv.reader(f) for row in data : print(row)
실행 결과
['사용월', '호선명', '역ID', '지하철역', '유임 승차', '유임하차', '무임 승차', '무임하차'] ['2019-01', '1호선', '0150', '서울역', '1516452', '1400464', '221180', '211764'] ['2019-01', '1호선', '0151', '시청', '676932', '676266', '102388', '101033'] ['2019-01', '1호선', '0152', '종각', '1240810', '1177643', '162410', '152062'] ['2019-01', '1호선', '0153', '종로3가', '703110', '674148', '387062', '362735'] ['2019-01', '1호선', '0154', '종로5가', '571824', '583955', '275447', '263687'] (생략)