Pagini recente » Borderou de evaluare (job #1319908) | Borderou de evaluare (job #1273480) | Borderou de evaluare (job #1273492) | Borderou de evaluare (job #1388574) | Borderou de evaluare (job #3036632)
Borderou de evaluare (job #3036632)
Raport evaluator
Compilare:
main.cpp: In function 'I z(I)':
main.cpp:4:206: warning: no return statement in function returning non-void [-Wreturn-type]
4 | using I=int;using namespace std;ifstream f("concurs.in");ofstream g("concurs.out");const I h=4e4;I p[h],a[h],b[h],t[h][16],n,m,x,y,r,c,d,q,s,u,i=1,j=1;set<I>e[h];I z(I x){a[x]=++d;W(I y:e[x])z(y);b[x]=++d;}I k(I x,I y){L a[x]<=a[y]&b[y]<=b[x];}I o(I x,I y){if(k(x,y))L x;if(k(y,x))L y;W(i=15;i>=0;i--)if(!k(t[x][i],y))x=t[x][i];L t[x][0];}main(){f>>n>>m;W(;i<=n;i++)f>>p[i];W(i=1;i<n;i++)f>>x>>y,t[y][0]=x,e[x].insert(y);W(i=1;i<=n;i++)r|=!t[i][0]*i;W(;j<16;j++)W(i=1;i<=n;i++){I&G=t[i][j];G=t[t[i][j-1]][j-1],G|=!G*r;}z(r);W(;m--;){f>>x>>y;c=p[o(x,y)];if(q<c|q==c&x<s|q==c&x==s&y<u)q=c,s=x,u=y;}g<<q<<' '<<s<<' '<<u;}
| ^
main.cpp: In function 'I k(I, I)':
main.cpp:4:226: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses]
4 | using I=int;using namespace std;ifstream f("concurs.in");ofstream g("concurs.out");const I h=4e4;I p[h],a[h],b[h],t[h][16],n,m,x,y,r,c,d,q,s,u,i=1,j=1;set<I>e[h];I z(I x){a[x]=++d;W(I y:e[x])z(y);b[x]=++d;}I k(I x,I y){L a[x]<=a[y]&b[y]<=b[x];}I o(I x,I y){if(k(x,y))L x;if(k(y,x))L y;W(i=15;i>=0;i--)if(!k(t[x][i],y))x=t[x][i];L t[x][0];}main(){f>>n>>m;W(;i<=n;i++)f>>p[i];W(i=1;i<n;i++)f>>x>>y,t[y][0]=x,e[x].insert(y);W(i=1;i<=n;i++)r|=!t[i][0]*i;W(;j<16;j++)W(i=1;i<=n;i++){I&G=t[i][j];G=t[t[i][j-1]][j-1],G|=!G*r;}z(r);W(;m--;){f>>x>>y;c=p[o(x,y)];if(q<c|q==c&x<s|q==c&x==s&y<u)q=c,s=x,u=y;}g<<q<<' '<<s<<' '<<u;}
| ~~~~^~~~~~
main.cpp: At global scope:
main.cpp:4:340: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
4 | using I=int;using namespace std;ifstream f("concurs.in");ofstream g("concurs.out");const I h=4e4;I p[h],a[h],b[h],t[h][16],n,m,x,y,r,c,d,q,s,u,i=1,j=1;set<I>e[h];I z(I x){a[x]=++d;W(I y:e[x])z(y);b[x]=++d;}I k(I x,I y){L a[x]<=a[y]&b[y]<=b[x];}I o(I x,I y){if(k(x,y))L x;if(k(y,x))L y;W(i=15;i>=0;i--)if(!k(t[x][i],y))x=t[x][i];L t[x][0];}main(){f>>n>>m;W(;i<=n;i++)f>>p[i];W(i=1;i<n;i++)f>>x>>y,t[y][0]=x,e[x].insert(y);W(i=1;i<=n;i++)r|=!t[i][0]*i;W(;j<16;j++)W(i=1;i<=n;i++){I&G=t[i][j];G=t[t[i][j-1]][j-1],G|=!G*r;}z(r);W(;m--;){f>>x>>y;c=p[o(x,y)];if(q<c|q==c&x<s|q==c&x==s&y<u)q=c,s=x,u=y;}g<<q<<' '<<s<<' '<<u;}
| ^~~~
main.cpp: In function 'int main()':
main.cpp:4:562: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses]
4 | using I=int;using namespace std;ifstream f("concurs.in");ofstream g("concurs.out");const I h=4e4;I p[h],a[h],b[h],t[h][16],n,m,x,y,r,c,d,q,s,u,i=1,j=1;set<I>e[h];I z(I x){a[x]=++d;W(I y:e[x])z(y);b[x]=++d;}I k(I x,I y){L a[x]<=a[y]&b[y]<=b[x];}I o(I x,I y){if(k(x,y))L x;if(k(y,x))L y;W(i=15;i>=0;i--)if(!k(t[x][i],y))x=t[x][i];L t[x][0];}main(){f>>n>>m;W(;i<=n;i++)f>>p[i];W(i=1;i<n;i++)f>>x>>y,t[y][0]=x,e[x].insert(y);W(i=1;i<=n;i++)r|=!t[i][0]*i;W(;j<16;j++)W(i=1;i<=n;i++){I&G=t[i][j];G=t[t[i][j-1]][j-1],G|=!G*r;}z(r);W(;m--;){f>>x>>y;c=p[o(x,y)];if(q<c|q==c&x<s|q==c&x==s&y<u)q=c,s=x,u=y;}g<<q<<' '<<s<<' '<<u;}
| ~^~~
main.cpp:4:565: warning: suggest parentheses around arithmetic in operand of '|' [-Wparentheses]
4 | using I=int;using namespace std;ifstream f("concurs.in");ofstream g("concurs.out");const I h=4e4;I p[h],a[h],b[h],t[h][16],n,m,x,y,r,c,d,q,s,u,i=1,j=1;set<I>e[h];I z(I x){a[x]=++d;W(I y:e[x])z(y);b[x]=++d;}I k(I x,I y){L a[x]<=a[y]&b[y]<=b[x];}I o(I x,I y){if(k(x,y))L x;if(k(y,x))L y;W(i=15;i>=0;i--)if(!k(t[x][i],y))x=t[x][i];L t[x][0];}main(){f>>n>>m;W(;i<=n;i++)f>>p[i];W(i=1;i<n;i++)f>>x>>y,t[y][0]=x,e[x].insert(y);W(i=1;i<=n;i++)r|=!t[i][0]*i;W(;j<16;j++)W(i=1;i<=n;i++){I&G=t[i][j];G=t[t[i][j-1]][j-1],G|=!G*r;}z(r);W(;m--;){f>>x>>y;c=p[o(x,y)];if(q<c|q==c&x<s|q==c&x==s&y<u)q=c,s=x,u=y;}g<<q<<' '<<s<<' '<<u;}
| ~~~~^~~~
main.cpp:4:571: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses]
4 | using I=int;using namespace std;ifstream f("concurs.in");ofstream g("concurs.out");const I h=4e4;I p[h],a[h],b[h],t[h][16],n,m,x,y,r,c,d,q,s,u,i=1,j=1;set<I>e[h];I z(I x){a[x]=++d;W(I y:e[x])z(y);b[x]=++d;}I k(I x,I y){L a[x]<=a[y]&b[y]<=b[x];}I o(I x,I y){if(k(x,y))L x;if(k(y,x))L y;W(i=15;i>=0;i--)if(!k(t[x][i],y))x=t[x][i];L t[x][0];}main(){f>>n>>m;W(;i<=n;i++)f>>p[i];W(i=1;i<n;i++)f>>x>>y,t[y][0]=x,e[x].insert(y);W(i=1;i<=n;i++)r|=!t[i][0]*i;W(;j<16;j++)W(i=1;i<=n;i++){I&G=t[i][j];G=t[t[i][j-1]][j-1],G|=!G*r;}z(r);W(;m--;){f>>x>>y;c=p[o(x,y)];if(q<c|q==c&x<s|q==c&x==s&y<u)q=c,s=x,u=y;}g<<q<<' '<<s<<' '<<u;}
| ~^~~
main.cpp:4:581: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses]
4 | using I=int;using namespace std;ifstream f("concurs.in");ofstream g("concurs.out");const I h=4e4;I p[h],a[h],b[h],t[h][16],n,m,x,y,r,c,d,q,s,u,i=1,j=1;set<I>e[h];I z(I x){a[x]=++d;W(I y:e[x])z(y);b[x]=++d;}I k(I x,I y){L a[x]<=a[y]&b[y]<=b[x];}I o(I x,I y){if(k(x,y))L x;if(k(y,x))L y;W(i=15;i>=0;i--)if(!k(t[x][i],y))x=t[x][i];L t[x][0];}main(){f>>n>>m;W(;i<=n;i++)f>>p[i];W(i=1;i<n;i++)f>>x>>y,t[y][0]=x,e[x].insert(y);W(i=1;i<=n;i++)r|=!t[i][0]*i;W(;j<16;j++)W(i=1;i<=n;i++){I&G=t[i][j];G=t[t[i][j-1]][j-1],G|=!G*r;}z(r);W(;m--;){f>>x>>y;c=p[o(x,y)];if(q<c|q==c&x<s|q==c&x==s&y<u)q=c,s=x,u=y;}g<<q<<' '<<s<<' '<<u;}
| ~^~
main.cpp:4:579: warning: suggest parentheses around arithmetic in operand of '|' [-Wparentheses]
4 | using I=int;using namespace std;ifstream f("concurs.in");ofstream g("concurs.out");const I h=4e4;I p[h],a[h],b[h],t[h][16],n,m,x,y,r,c,d,q,s,u,i=1,j=1;set<I>e[h];I z(I x){a[x]=++d;W(I y:e[x])z(y);b[x]=++d;}I k(I x,I y){L a[x]<=a[y]&b[y]<=b[x];}I o(I x,I y){if(k(x,y))L x;if(k(y,x))L y;W(i=15;i>=0;i--)if(!k(t[x][i],y))x=t[x][i];L t[x][0];}main(){f>>n>>m;W(;i<=n;i++)f>>p[i];W(i=1;i<n;i++)f>>x>>y,t[y][0]=x,e[x].insert(y);W(i=1;i<=n;i++)r|=!t[i][0]*i;W(;j<16;j++)W(i=1;i<=n;i++){I&G=t[i][j];G=t[t[i][j-1]][j-1],G|=!G*r;}z(r);W(;m--;){f>>x>>y;c=p[o(x,y)];if(q<c|q==c&x<s|q==c&x==s&y<u)q=c,s=x,u=y;}g<<q<<' '<<s<<' '<<u;}
| ~~~~~~~~~^~~~
main.cpp: In function 'I z(I)':
main.cpp:4:165: warning: infinite recursion detected [-Winfinite-recursion]
4 | using I=int;using namespace std;ifstream f("concurs.in");ofstream g("concurs.out");const I h=4e4;I p[h],a[h],b[h],t[h][16],n,m,x,y,r,c,d,q,s,u,i=1,j=1;set<I>e[h];I z(I x){a[x]=++d;W(I y:e[x])z(y);b[x]=++d;}I k(I x,I y){L a[x]<=a[y]&b[y]<=b[x];}I o(I x,I y){if(k(x,y))L x;if(k(y,x))L y;W(i=15;i>=0;i--)if(!k(t[x][i],y))x=t[x][i];L t[x][0];}main(){f>>n>>m;W(;i<=n;i++)f>>p[i];W(i=1;i<n;i++)f>>x>>y,t[y][0]=x,e[x].insert(y);W(i=1;i<=n;i++)r|=!t[i][0]*i;W(;j<16;j++)W(i=1;i<=n;i++){I&G=t[i][j];G=t[t[i][j-1]][j-1],G|=!G*r;}z(r);W(;m--;){f>>x>>y;c=p[o(x,y)];if(q<c|q==c&x<s|q==c&x==s&y<u)q=c,s=x,u=y;}g<<q<<' '<<s<<' '<<u;}
| ^
main.cpp:4:193: note: recursive call
4 | using I=int;using namespace std;ifstream f("concurs.in");ofstream g("concurs.out");const I h=4e4;I p[h],a[h],b[h],t[h][16],n,m,x,y,r,c,d,q,s,u,i=1,j=1;set<I>e[h];I z(I x){a[x]=++d;W(I y:e[x])z(y);b[x]=++d;}I k(I x,I y){L a[x]<=a[y]&b[y]<=b[x];}I o(I x,I y){if(k(x,y))L x;if(k(y,x))L y;W(i=15;i>=0;i--)if(!k(t[x][i],y))x=t[x][i];L t[x][0];}main(){f>>n>>m;W(;i<=n;i++)f>>p[i];W(i=1;i<n;i++)f>>x>>y,t[y][0]=x,e[x].insert(y);W(i=1;i<=n;i++)r|=!t[i][0]*i;W(;j<16;j++)W(i=1;i<=n;i++){I&G=t[i][j];G=t[t[i][j-1]][j-1],G|=!G*r;}z(r);W(;m--;){f>>x>>y;c=p[o(x,y)];if(q<c|q==c&x<s|q==c&x==s&y<u)q=c,s=x,u=y;}g<<q<<' '<<s<<' '<<u;}
| ~^~~
Test |
Timp executie |
Memorie folosita |
Mesaj |
Punctaj/test |
1 | 5ms | 2420kb | Killed by Signal 11 | 0 |
2 | 5ms | 2424kb | Killed by Signal 11 | 0 |
3 | 5ms | 2482kb | Killed by Signal 11 | 0 |
4 | 6ms | 2781kb | Killed by Signal 11 | 0 |
5 | 6ms | 2772kb | Killed by Signal 11 | 0 |
6 | 8ms | 3624kb | Killed by Signal 11 | 0 |
7 | 12ms | 6504kb | Killed by Signal 11 | 0 |
8 | 10ms | 4755kb | Killed by Signal 11 | 0 |
9 | 14ms | 5959kb | Killed by Signal 11 | 0 |
10 | 12ms | 6037kb | Killed by Signal 11 | 0 |
Punctaj total | 0 |