我有这个代码,我正在尝试使用列表拆分 但要么我得到太多的值来解包或需要超过0值来解包
def edits1(word):
splits = [(word[:i], word[i:]) for i in range(len(word) + 1)]
temp1 = []
for i in splits:
temp = list(i)
for j in range(0,len(temp)):
temp1.append(temp[j])
splits = temp1
for s in splits:
print s
#here
deletes = [a + b[1:] for a, b in splits if b]
return set(deletes)