我有以下列表
lines =
[['client', 'name', 'phone', 'address', 'email'],
['client2', 'name2', 'phone2', 'address2', 'email2'],
['client3', 'name3', 'phone3', 'address3', 'email3']]
我想知道是否可以将列表转换为 dic 列表。
喜欢:
lines =
[{Client: client, Name:name, Phone:phone, Address:address, Email:email},
{Client: client2, Name:name2, Phone:phone2, Address:address2, Email:email2},
{Client: client3, Name:name3, Phone:phone3, Address:address3, Email:email3}]