Skip to content

Commit c5bd636

Browse files
Update doubly_linked_list_two.py
1 parent 13b560c commit c5bd636

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

data_structures/linked_list/doubly_linked_list_two.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,8 +135,6 @@ def insert_at_position(self, position: int, value: int) -> None:
135135
return
136136
current_position += 1
137137
node = node.next
138-
if not self.tail:
139-
raise IndexError(position)
140138
self.insert_after_node(self.tail, new_node)
141139

142140
def get_node(self, item: int) -> Node:

0 commit comments

Comments
 (0)