-- coding:utf-8 -- class ListNode: def init(self, x): self.val = x self.next = Noneclass Solution: # 返回ListNode def ReverseList(self, pHead): # write code here #首先判断头节点为空或者单个节点的情况 if pHead is None: return pHead if pHead.next is None: return pHead #保存三个节点:当前节点,当前节点的前节点,当前节点的下一个节点 #初始化的时候当前节点是头节点,前节点为...