Skip to content

Commit

Permalink
Fix node for sortLinkedList.py
Browse files Browse the repository at this point in the history
  • Loading branch information
huangsam committed Oct 28, 2024
1 parent f09c3b6 commit fb7702b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/sortLinkedList.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ def getMiddle(self, head: ListNode) -> ListNode:
return slow

def mergeSortedLists(self, l1: ListNode, l2: ListNode) -> ListNode:
dummy = ListNode(None)
dummy = ListNode()
node = dummy
while l1 and l2:
if l1.val < l2.val:
Expand Down

0 comments on commit fb7702b

Please sign in to comment.