Skip to content

Instantly share code, notes, and snippets.

@songpu2015617
Created April 19, 2015 03:53
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 songpu2015617/30a68118bc70eccd5944 to your computer and use it in GitHub Desktop.
Save songpu2015617/30a68118bc70eccd5944 to your computer and use it in GitHub Desktop.
cc150 2.3
#include<iostream>
using namespace std;
typedef struct node{
int data;
node *next;
}node;
void removemid(node *mid){
if (mid==NULL||mid->next=NULL) return;
node*q=mid->next;
mid->data=q->data;
mid->next=q->next;
delete q;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment