class Solution:
# 返回ListNode
def ReverseList(self, pHead):
# write code here
c=pHead
p=None
while c:
l=c.next
c.next=p
p=c
c=l
return p
class Solution:
# 返回ListNode
def ReverseList(self, pHead):
# write code here
c=pHead
p=None
while c:
l=c.next
c.next=p
p=c
c=l
return p