mirror of
https://github.com/donnemartin/interactive-coding-challenges
synced 2026-01-14 21:38:02 +00:00
Added linked list challenge.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
|
||||
class Node(object):
|
||||
|
||||
def __init__(self, data, next_node=None):
|
||||
self.next = next_node
|
||||
self.data = data
|
||||
@@ -8,6 +8,7 @@ class Node(object):
|
||||
return self.data
|
||||
|
||||
class LinkedList(object):
|
||||
|
||||
def __init__(self, head=None):
|
||||
self.head = head
|
||||
|
||||
|
||||
Reference in New Issue
Block a user