#include "malloc.h"
#include "stdio.h"
#define NULL 0
struct LO
{int data;
struct LO *next;
};
struct LO *creat(void)
{struct LO La,*head,*p1,*p2;
int i,j,n=0;i=0;
p1=p2=malloc(sizeof(struct LO));
p1->data=0;
p1->next=NULL; printf("please input a number\n"); head=P1;
while(i<m)
{p2=malloc(sizeof(stuct LO));
scanf("%d",&p1->data);
p2->next=NULL; p1->next=p2;p1=p1->next;
}
return(head);
}
void insert(struct LO*head,int i,int e)
{struct LO *p0,*p1,*p2;
int j=0;
p0=malloc(sizeof(struct LO)); p1=head;
if(head==NULL){head=p0;p0->next=NULL;}
eles{while(p1->next!=NULL&&j<=i-1)
{p1=p1->next,++j;}
p0->data=e;p0->next=p1->naxt;p1->next=p0;}
}
void del(structLO*head,int i)
{struct LO *p1,*p2; int j
p1=head;j=0;
while(p1->naxt&&j<i-1)
{p1=p1->next;j++;
}
q=p1->next;p->next=q=>next;
e=q->data;free(q);printf("%d",e);
}
main()
{stuct LO LA,LB,*p;
inti.j.m,e;
m=structLO*creat(void);
putchar();
printf("please inpput the number");
scanf("%d%d",&i,&e);
strict LO*insert(stuct LO *m,int i,int e)
printf("please input a number");
scanf("%d",&j);
if(i!=5)printf("error\nplease input a rigth number");
else void del(struct LO *head,int i);
}