Borderou de evaluare (job #1514265)
Utilizator | Data | 30 octombrie 2015 21:56:10 | |
---|---|---|---|
Problema | Fence | 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:17:53: error: ‘max’ was not declared in this scope
for(j=nc-1;j>=cs+1;j--) b[j]=max(b[j+1],b[j]);
^
user.cpp:27:48: error: ‘max’ was not declared in this scope
for(j=2;j<=cn;j++) b[j]=max(b[j-1],b[j]);
^
user.cpp:38:53: error: ‘max’ was not declared in this scope
for(j=nc-1;j>=cn+1;j--) b[j]=max(b[j+1],b[j]);
^
user.cpp:48:50: error: ‘max’ was not declared in this scope
for(j=2;j<=cs-1;j++) b[j]=max(b[j-1],b[j]);
^
user.cpp:52:23: warning: format ‘%d’ expects argument of type ‘int’, but argument 2 has type ‘long int’ [-Wformat=]
printf("%I64d\n",smax);
^
user.cpp:6:31: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
{freopen("fence.in","r",stdin);freopen("fence.out","w",stdout);
^
user.cpp:6:63: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
{freopen("fence.in","r",stdin);freopen("fence.out","w",stdout);
^
user.cpp:7:80: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%hd %hd %hd %hd %hd %hd %hd %hd\n",&ceri,&nl,&nc,&pret,&cn,&cs,&lv,&le);
^
user.cpp:9:36: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
for(j=1;j<=nc;j++){scanf("%hd ",&x);a[i][j]=x-pret;if (i<lv && j<cn);else if(i<le && j>cn);else if(i>lv && j<cs);else if(i>le && j>cs);else smax+=a[i][j];}
^
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !