foo.c:7:7: error: expected ':', ',', ';', '}' or '__attribute__' before '=' token
int a=0,b=0,c=0;
^
foo.c: In function 'main':
foo.c:19:27: error: 'struct cj' has no member named 'a'
scanf("%d %d %d",&phb[i].a,&phb[i].b,&phb[i].c);
^
foo.c:19:37: error: 'struct cj' has no member named 'b'
scanf("%d %d %d",&phb[i].a,&phb[i].b,&phb[i].c);
^
foo.c:19:47: error: 'struct cj' has no member named 'c'
scanf("%d %d %d",&phb[i].a,&phb[i].b,&phb[i].c);
^
foo.c:21:9: error: 'struct cj' has no member named 'sum'
phb[i].sum = phb[i].a + phb[i].b + phb[i].c;
^
foo.c:21:22: error: 'struct cj' has no member named 'a'
phb[i].sum = phb[i].a + phb[i].b + phb[i].c;
^
foo.c:21:33: error: 'struct cj' has no member named 'b'
phb[i].sum = phb[i].a + phb[i].b + phb[i].c;
^
foo.c:21:44: error: 'struct cj' has no member named 'c'
phb[i].sum = phb[i].a + phb[i].b + phb[i].c;
^
foo.c:27:13: error: 'struct cj' has no member named 'sum'
if(phb[j].sum<phb[j+1].sum)
^
foo.c:27:26: error: 'struct cj' has no member named 'sum'
if(phb[j].sum<phb[j+1].sum)
^
foo.c:33:18: error: 'struct cj' has no member named 'sum'
else if(phb[j].sum==phb[j+1].sum)
^
foo.c:33:32: error: 'struct cj' has no member named 'sum'
else if(phb[j].sum==phb[j+1].sum)
^
foo.c:35:14: error: 'struct cj' has no member named 'a'
if(phb[j].a<phb[j+1].a)
^
foo.c:35:25: error: 'struct cj' has no member named 'a'
if(phb[j].a<phb[j+1].a)
^
foo.c:46:38: error: 'struct cj' has no member named 'sum'
printf("%d %d\n",phb[i].name,phb[i].sum);
^
foo.c:16:2: warning: ignoring return value of 'scanf', declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&n);
^~~~~~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务