为什么会出现内存不能读
											大家能告诉我盖如何改,才能运行成功呢(我编的是带头节点的,要是不要带头节点就不会出现那种情况。但是我感觉
带头节点的链表会方便的多,所以就想用这个,但是怎么就不行呢)
#include "stdio.h"
#include "stdlib.h"
#define ELEM struct elemtype
#define SIZE sizeof(ELEM)
ELEM{
    int date;
    ELEM *next;
};
void create(ELEM **head)
{
    int stno;
    ELEM *p,*tail;
    *head=(ELEM *)malloc(SIZE);
    (*head)->next=NULL;
    printf("please input the initial numbers -1 to stop\n");
    scanf("%d",&stno);
    while(stno!=-1){
        p=(ELEM *)malloc(SIZE);
        p->date=stno;
        p->next=NULL;
        p->next=tail;
        tail=p;
        scanf("%d",&stno);
    }
    for(p=(*head)->next;p->next!=NULL;*p++){
    printf("%8d",p->date);
    }
}
main()
{
    ELEM *h1;
    create(h1);
}



 
											





 
	    

 
	