题解 | #反转链表#
查找最晚入职员工的所有信息
http://www.nowcoder.com/practice/218ae58dfdcd4af195fff264e062138f
统计
def ReverseList(self, pHead): # write code here if pHead == None or pHead.next == None: # 若链表为空或者仅一个数就直接返回 return pHead pre = None next = None while (pHead != None): next = pHead.next # 1 pHead.next = pre # 2 pre = pHead # 3 pHead = next # 4 return pre