Borderou de evaluare (job #2950900)
Utilizator | Data | 4 decembrie 2022 20:09:31 | |
---|---|---|---|
Problema | Subsir crescator maximal | Status | done |
Runda | Arhiva educationala | Compilator | cpp-64 | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp:1:2: warning: #import is a deprecated GCC extension [-Wdeprecated]
1 | #import<fstream>
| ^~~~~~
main.cpp:2:94: error: ISO C++ forbids declaration of 'a' with no type [-fpermissive]
2 | std::ifstream f("scmax.in");std::ofstream g("scmax.out");int v[1<<20],p[1<<20],q[9999],i,j,Q;a(int Z){while(p[--Z]!=Q);if(--Q)a(Z);g<<v[Z]<<" ";}
| ^
main.cpp: In function 'int a(int)':
main.cpp:2:145: warning: no return statement in function returning non-void [-Wreturn-type]
2 | std::ifstream f("scmax.in");std::ofstream g("scmax.out");int v[1<<20],p[1<<20],q[9999],i,j,Q;a(int Z){while(p[--Z]!=Q);if(--Q)a(Z);g<<v[Z]<<" ";}
| ^
main.cpp: At global scope:
main.cpp:3:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
3 | main(){f>>j;for(;f>>v[i];q[j]=v[i++]){for(j=0;v[i]>q[j]&j<=Q;p[i]=++j);Q+=j>Q;}g<<Q<<" ";a(i);}
| ^~~~
main.cpp: In function 'int main()':
main.cpp:3:51: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses]
3 | main(){f>>j;for(;f>>v[i];q[j]=v[i++]){for(j=0;v[i]>q[j]&j<=Q;p[i]=++j);Q+=j>Q;}g<<Q<<" ";a(i);}
| ~~~~^~~~~
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !