[求助]结构体赋值
请问为什么不能对以下结构体变量中的实型变量赋值,多谢
struct student
{
int num;
char name[8];
float score;
struct student * next;
}stud;
main()
{
struct student *p;
p=&stud;
printf("input the recorder:(num name score)\n");
scanf("%d%s%f",&p->num,p->name,&p->score);
printf("num=%d %s score=%g\n",p->num,p->name,p->score);
}