Skip to content

Commit 934a5ef

Browse files
Update AddTwoNumbers.py
1 parent 90fa3de commit 934a5ef

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Add Two Numbers/AddTwoNumbers.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# 第一种思路
2-
# 将两个链表转换为数字,然后加累加得到的结果再转换为链表,效率比较低
2+
# 将两个链表转换为数字,然后将累加得到的结果再转换为链表,效率比较低
33
# 112ms 86.57%
44

55
# Definition for singly-linked list.
@@ -81,4 +81,4 @@ def addTwoNumbers(self, l1, l2):
8181

8282
if carry is not 0:
8383
mid.next =ListNode(carry)
84-
return head
84+
return head

0 commit comments

Comments
 (0)