I have a csv file
col1, col2, col3
1, 2, 3
4, 5, 6
I want to create a list of dictionary from this csv.
output as :
a= [{'col1':1, 'col2':2, 'col3':3}, {'col1':4, 'col2':5, 'col3':6}]
How can I do this?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…