Pagini recente » Borderou de evaluare (job #1088281) | Borderou de evaluare (job #2719736) | Borderou de evaluare (job #2646469) | Borderou de evaluare (job #2847995) | Borderou de evaluare (job #2740028)
Borderou de evaluare (job #2740028)
Raport evaluator
Compilare:
main.cpp:3:128: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
using namespace std;ifstream I("reteta2.in");ofstream O("reteta2.out");map<string,int>i;char r[999],*S,*c,m[]="( )";int T;main(){I.get(r,1000);S=strtok(r,m);while(S){if(*S>'/'&*S<':')T+=atoi(S);else{c=q;i[S]+=atoi(c);}S=q}O<<T<<'\n';for(auto t:i)O<<t.first<<' '<<t.second<<'\n';}
^
main.cpp: In function 'int main()':
main.cpp:3:172: warning: suggest parentheses around comparison in operand of '&' [-Wparentheses]
using namespace std;ifstream I("reteta2.in");ofstream O("reteta2.out");map<string,int>i;char r[999],*S,*c,m[]="( )";int T;main(){I.get(r,1000);S=strtok(r,m);while(S){if(*S>'/'&*S<':')T+=atoi(S);else{c=q;i[S]+=atoi(c);}S=q}O<<T<<'\n';for(auto t:i)O<<t.first<<' '<<t.second<<'\n';}
~~^~~~
Test |
Timp executie |
Memorie folosita |
Mesaj |
Punctaj/test |
1 | 3ms | 131kb | OK! | 10 |
2 | 2ms | 131kb | OK! | 10 |
3 | 2ms | 131kb | OK! | 10 |
4 | 3ms | 131kb | OK! | 10 |
5 | 2ms | 131kb | OK! | 10 |
6 | 3ms | 131kb | OK! | 10 |
7 | 2ms | 131kb | OK! | 10 |
8 | 3ms | 131kb | OK! | 10 |
9 | 3ms | 131kb | OK! | 10 |
10 | 2ms | 131kb | OK! | 10 |
Punctaj total | 100 |