import csv
import os
folder = 'D:/PROGRAMMING/PythonCode/data_arrange/'
fname_sum = 'sum.csv'
bump = 6
csv_filenames = [f for f in os.listdir(folder) if f.endswith('.csv') and f.startswith('raw')]
for c in csv_filenames:
# open the file in read mode
with open(folder+c, 'r', encoding="utf-8") as file:
reader = csv.reader(file) # 自動使用第一行作為欄位名稱
data = list(reader) # 讀取所有行(列表的列表)
columns = list(map(list, zip(*data))) # 使用 zip 轉置資料,並轉成 list
break
print(columns)