word = ["yellow", "accent", "call", "excel", "tea", "little", "brother"] #存储结点的数据区域
turn = [4,-1,6,2,5,3,1] #存储结点的指针区域
del_word = input("请输入要删除的单词:")
head = 0 #头指针为head
pre_point = -1
while point != -1:
if :
point = turn[point]
break #break退出当前循环
pre_point = point
point = turn[point]
if pre_point == -1: #删除头节点
head = point
elif point == -1: #删除尾节点
turn[pre_point] = -1
else:
turn[pre_point] = point
point = head
print("删除单词后词典为:")
while point != -1:
print(word[point],end=" ")
print('\n')