0_0_20614390_15092.cpp:4:5: error: 'y' does not name a type
y.c;}int main(){ int n; while(cin>>n) { for(int i=0;i<n;i++) { cin>>mapp[i].a>>mapp[i].b; mapp[i].c=mapp[i].a-mapp[i].b; mapp[i].id=i; } sort(mapp,mapp+n,cmp); cout<<mapp[0].id; for(int i=1;i<n;i++) cout<<" "<<mapp[i].id; cout<<endl; } return 0;}
^
0_0_20614390_15092.cpp:4:9: error: expected declaration before '}' token
y.c;}int main(){ int n; while(cin>>n) { for(int i=0;i<n;i++) { cin>>mapp[i].a>>mapp[i].b; mapp[i].c=mapp[i].a-mapp[i].b; mapp[i].id=i; } sort(mapp,mapp+n,cmp); cout<<mapp[0].id; for(int i=1;i<n;i++) cout<<" "<<mapp[i].id; cout<<endl; } return 0;}
^
|