单链表问题!!!求调试
struct student{
long No;
int Noclass;
char name[10];
int class1,class2,class3,class4,class5;
double avg;
}std[180];
struct student1
{
long No;
int NoClass;
char name[10];
double avg;
struct student1 *next;
}std1[180];
int newlink()
{
int i,j,temp;
for(i=0;i<180;i++)
{
std1[i].No=std[i].No;
for(j=0;j<6;j++)
{
std1[i].name[j] =std[i].name[j];
}
std1[i].NoClass =std[i].Noclass;
std1[i].avg=std[i].avg;
std1[i].next=&std1[i+1].No;
}
for(i=0;i<180;i++)
{
for(j=i+1;j<181;j++)
{
if(std1[i].avg < std1[j].avg)
{
temp=std1[i].avg;
std1[i].avg=std1[j].avg ;
std1[j].avg =temp;
}
}
}
return 1;
}
标记那行总是error C2440: '=' : cannot convert from 'long *' to 'struct student1 *'
怎么办!!!