为什么我输入的东西都输不出来,谁帮我看一下程序
:#include <stdio.h>#define NULL 0
#define LEN sizeof(struct canode)
typedef struct canode
{char ca;
struct canode *next;
}Cnode,*Clist;
creat()
{Cnode *rear,*s,*lc,*p;
char c;
lc=(struct canode *)malloc(LEN);
rear=lc;
printf("Ener a paper,#,END");c=getchar();s->ca=c;
while(c!='#')
{rear->next=s;
rear=s;
c=getchar();
s->ca=c;}
rear->next=NULL;
return(lc);
}
print(Cnode *l)
{struct Clist *p;
p=l;
p=p->next;
if(p!=NULL)
do{printf("%c",p->ca);
p=p->next;
}while(p!=NULL);
}
void main()
{Clist *L;
int p1;
L=creat();
print(L);}