Borderou de evaluare (job #1546259)
Utilizator | Data | 7 decembrie 2015 21:10:07 | |
---|---|---|---|
Problema | Color5 | Status | done |
Runda | Arhiva de probleme | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp: In function ‘int main()’:
user.cpp:7:19: warning: format ‘%d’ expects argument of type ‘int*’, but argument 2 has type ‘int (*)[100]’ [-Wformat=]
scanf("%d", &n);
^
user.cpp:8:5: error: ‘s’ was not declared in this scope
s=0;
^
user.cpp:10:16: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
for(i=1;i<=n;i++)
^
user.cpp:4:34: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("cmmdc.in","r",stdin);
^
user.cpp:5:36: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("cmmdc.out","w",stdout);
^
user.cpp:7:20: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d", &n);
^
user.cpp:12:27: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d", &n[i]);
^
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !