leetcode 24:两两交换链表中的节点
难度等级:中等 ⭐⭐
def swapPairs(self, head: ListNode) -> ListNode: pre = dummy = ListNode(0) dummy.next = head # pre, pre.next = self, head while pr