/in/foo.cc: In function 'int main()':
/in/foo.cc:5:21: error: 's' was not declared in this scope
scanf("%lf%d",&s,&n);
^
/in/foo.cc:5:24: error: 'n' was not declared in this scope
scanf("%lf%d",&s,&n);
^
/in/foo.cc:6:28: error: 'x' was not declared in this scope
while(scanf("%d%d%lf",&x,&y,&z)!=EOF)
^
/in/foo.cc:6:31: error: 'y' was not declared in this scope
while(scanf("%d%d%lf",&x,&y,&z)!=EOF)
^
/in/foo.cc:6:34: error: 'z' was not declared in this scope
while(scanf("%d%d%lf",&x,&y,&z)!=EOF)
^
/in/foo.cc:8:9: error: 'j' was not declared in this scope
j++;
^
/in/foo.cc:9:9: error: 'e' was not declared in this scope
e[j].x=x;e[j].y=y;e[j].z=z;
^
/in/foo.cc:11:10: error: 'e' was not declared in this scope
sort(e+1,e+j+1,cmp);
^
/in/foo.cc:11:16: error: 'j' was not declared in this scope
sort(e+1,e+j+1,cmp);
^
/in/foo.cc:11:20: error: 'cmp' was not declared in this scope
sort(e+1,e+j+1,cmp);
^~~
/in/foo.cc:11:23: error: 'sort' was not declared in this scope
sort(e+1,e+j+1,cmp);
^
/in/foo.cc:13:9: error: 'fa' was not declared in this scope
fa[i]=i;
^~
/in/foo.cc:16:27: error: 'find' was not declared in this scope
int fx=find(e[i].x);
^
/in/foo.cc:20:13: error: 'fa' was not declared in this scope
fa[fx]=fy;
^~
/in/foo.cc:21:13: error: 'cnt' was not declared in this scope
cnt++;
^~~
/in/foo.cc:22:13: error: 'ans' was not declared in this scope
ans+=e[i].z;
^~~
/in/foo.cc:24:12: error: 'cnt' was not declared in this scope
if(cnt==n-1)
^~~
/in/foo.cc:27:8: error: 'ans' was not declared in this scope
if(ans<=s && cnt==n-1)
^~~
/in/foo.cc:27:18: error: 'cnt' was not declared in this scope
if(ans<=s && cnt==n-1)
^~~