谁来帮我看看错误呀!
谁来帮我看看错误呀!#include <stdio.h>
#define N 5
struct student
{
int num;
char *name;
char sex;
float score;
};
void main()
{
struct student stu[N];
int i;
for(i=0;i<5;++i)
{
printf("请输入第%d个学员的信息:\n"i+1);
printf("学号:");
scanf("%d",&stu[i].num);
printf("姓名:");
fflush(stdin);
gets(stu[i].name);
}
}错误说明是C:\Documents and Settings\Administrator\桌面\jj\jj.c(16) : error C2146: syntax error : missing ')' before identifier 'i'
C:\Documents and Settings\Administrator\桌面\jj\jj.c(16) : error C2059: syntax error : ')'
执行 cl.exe 时出错.