Created
April 19, 2015 03:53
-
-
Save songpu2015617/30a68118bc70eccd5944 to your computer and use it in GitHub Desktop.
cc150 2.3
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#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