#include "stdafx.h"
#include<stdio.h>
#include<malloc.h>
#include<stdlib.h>
typedef int type;
typedef struct lnode //定义链表结点的数据结构
{
int data;
struct lnode *next;
}Lnode;
typedef Lnode node;
typedef struct dnode//定义双链表结点的数据结构
{
int data;
struct dnode *lnext;
struct dnode *rnext;
}Dnode;
void recursiondel1(node *h, type x)
{
node *p;
if (h == NULL)
return;
if (h->data == x)
{
p = h;
h = h->next;
free(p);
recursiondel1(h, x);
}
else
recursiondel1(h->next, x);
}