From d09c3b81429ada68e6f20771c572c55b6ebb35b8 Mon Sep 17 00:00:00 2001 From: luucamay Date: Wed, 2 Oct 2019 22:02:54 -0400 Subject: [PATCH] solving a bug with the previous node --- linked_list/p2.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linked_list/p2.py b/linked_list/p2.py index cde5c39..f6619dc 100644 --- a/linked_list/p2.py +++ b/linked_list/p2.py @@ -15,7 +15,7 @@ def remove_duplicates(self): previous.next = node.next else: els.append(node.val) - previous = node + previous = node node = node.next if __name__ == "__main__":