0_0_37295628_8144.cpp:6:1: error: expected unqualified-id before '{' token
{
^
0_0_37295628_8144.cpp:9:2: error: 'a' does not name a type
}a[100];
^
0_0_37295628_8144.cpp:10:11: error: expected ',' or '...' before '.' token
bool cmp(s.a,s.b)
^
0_0_37295628_8144.cpp: In function 'bool cmp(s)':
0_0_37295628_8144.cpp:10:10: error: '<anonymous>' has incomplete type
bool cmp(s.a,s.b)
^
0_0_37295628_8144.cpp:5:8: error: forward declaration of 'struct s'
struct s;
^
0_0_37295628_8144.cpp:12:9: error: 'a' was not declared in this scope
return a.num>b.num;
^
0_0_37295628_8144.cpp:12:15: error: 'b' was not declared in this scope
return a.num>b.num;
^
0_0_37295628_8144.cpp: In function 'int main()':
0_0_37295628_8144.cpp:21:18: error: 'a' was not declared in this scope
scanf("%s %d",a[i].color,&a[i].num)
^
0_0_37295628_8144.cpp:23:8: error: 'a' was not declared in this scope
sort(a,a+n,cmp);
^
|