如果单词匹配,我想将内部列表的第一个值(数字)传递给 dict
缓冲 :
['from',
'landi',
'stsci',
'edu',
'four'...]
列表_1:
[('focus', [-1, -2]),
('four', [-3.3, -1.04]),
...)]
for key in docs_A_rec:
for word, number_1,number_2 in list_1:
if word in buffer:
docs_A_rec[key]['idf'][word] = list_1[word][number_1]
我收到此错误:
ValueError: need more than 2 values to unpack
谢谢你。