Skip to content

Commit 87f24b1

Browse files
committed
Improved python
1 parent 1f99402 commit 87f24b1

File tree

3 files changed

+7
-0
lines changed

3 files changed

+7
-0
lines changed

src/main/python/g0001_0100/s0002_add_two_numbers/Solution.py renamed to src/main/python/g0001_0100/s0002_add_two_numbers/Solution0002.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,13 @@
33
# #Top_Interview_150_Linked_List #Big_O_Time_O(max(N,M))_Space_O(max(N,M))
44
# #AI_can_be_used_to_solve_the_task #2025_07_22_Time_0_ms_(100.00%)_Space_17.84_MB_(56.69%)
55

6+
from typing import Optional
7+
8+
class ListNode:
9+
def __init__(self, val=0, next=None):
10+
self.val = val
11+
self.next = next
12+
613
# Definition for singly-linked list.
714
# class ListNode:
815
# def __init__(self, val=0, next=None):

0 commit comments

Comments
 (0)