文件DoubleList.h
typedefstructDulNode{
intdata;
structDulNode*prior;
structDulNode*next;
}DulNode;
文件DoubleList.c
Head*InitLink(){
printf("请输入节点的值,0为结束标志:");
Head*p;
DulNode*q,*s;
intelem;
p=(structHead*)malloc(sizeof(Head));
p->head=NULL;p->lenght=0;
q=(DulNode*)malloc(sizeof(DulNode));
scanf("%d",&elem);
while(elem){
s=(DulNode*)malloc(sizeof(DulNode));
s->data=elem;
if(p->head==NULL){
p->head=s;
p->lenght+=1;
s->prior=s;
s->next=s;
q=s;
}
else{
q->next=s;
s->prior=q;
q->prior=s;
s->next=q;
p->lenght+=1;
}
scanf("%d",&elem);
}
free(q);
returnp;
}
typedefstructHead{
intlenght;
structDulNode*head;
}Head;
请问为什么会报'Head':illegaluseofthistypeasanexpression错误.哪位大侠能帮帮忙.小弟非常感激.