For the following code in python, I am getting the error--AttributeError: 'str' object has no attribute 'next'

前端 未结 0 1959
北恋
北恋 2020-12-19 12:33

def insertAfter(self, prevNode, newData): if prevNode is None: print("The given node must be in the linked list") return newNode = Node(newData) newNode.next = pre

相关标签:
回答
  • 消灭零回复
提交回复
热议问题