python實現鏈表翻轉

class Solution: # 返回ListNode def ReverseList(self, pHead): # write code here c=pHead p=None while c: l=c.next c.next=p p=c
相關文章
相關標籤/搜索