From 202599fe0c212771bff5a1d8a9edd334f136daa8 Mon Sep 17 00:00:00 2001 From: Donne Martin Date: Mon, 11 May 2015 19:51:05 -0400 Subject: [PATCH] Tweak algorithm, no need to set the curr node as it is passed in. Added check for error cases. --- linked-lists/delete-mid.ipynb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/linked-lists/delete-mid.ipynb b/linked-lists/delete-mid.ipynb index 325f312..dfd6266 100644 --- a/linked-lists/delete-mid.ipynb +++ b/linked-lists/delete-mid.ipynb @@ -45,7 +45,7 @@ "\n", "We'll need two pointers, one to the current node and one to the next node. We will copy the next node's data to the current node's data (effectively deleting the current node) and update the current node's next pointer.\n", "\n", - "* Set curr and next pointers\n", + "* Check for error cases listed above\n", "* set curr.data to next.data\n", "* set curr.next to next.next\n", "\n",