Skip to content

Instantly share code, notes, and snippets.

@hli42

hli42/cc150_2_3 Secret

Created May 28, 2015 02:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save hli42/bf0168666f8f66196aaf to your computer and use it in GitHub Desktop.
Save hli42/bf0168666f8f66196aaf to your computer and use it in GitHub Desktop.
public void deleteMidNode(Node mid){
if(mid == null){
return;
}
if(mid.next == null){
mid = null;
}
mid.val = mid.next.val;
mid.next = mid.next.next;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment