Pagini recente » Cod sursa (job #2963545) | Borderou de evaluare (job #1080694) | Cod sursa (job #583355) | Borderou de evaluare (job #3006454) | Borderou de evaluare (job #1417920)
Borderou de evaluare (job #1417920)
Raport evaluator
Compilare:
user.cpp:4:295: warning: "/*" within comment [-Wcomment]
X ++;Y = X * 1LL * (X+1) / 2;for(i = 1; i <= N-X-2; i ++) /*V[++T] = i;*/fprintf(fout,"%d ", i);Z = K-Y; Z = N-X-1+Z; fprintf(fout,"%d ", Z);for(i = N; i >= N-X-1; i --)if(i == Z) continue;else fprintf(fout,"%d ", i);/*for(i = 1; i <= N; i ++) /*fout << V[i] << " ";*//*fprintf(fout,"%d ", V[i]);*/return;}int main(){CodeExpert();return 0;}
^
user.cpp: In function ‘void CodeExpert()’:
user.cpp:3:264: warning: format ‘%d’ expects argument of type ‘int*’, but argument 3 has type ‘long long unsigned int*’ [-Wformat=]
/*ifstream fin ("farfurii.in" );*/FILE *fin = fopen("farfurii.in", "r");/*ofstream fout("farfurii.out");*/FILE *fout = fopen("farfurii.out","w");unsigned long long N, M, i, j, K, ok, minim, T, X, Y, Z;void CodeExpert(){/*fin >> N >> K;*/fscanf(fin, "%d%d", &N, &K); X = 1;while((X+1) * 1LL * (X+2) <= K * 2)
^
user.cpp:3:264: warning: format ‘%d’ expects argument of type ‘int*’, but argument 4 has type ‘long long unsigned int*’ [-Wformat=]
user.cpp:4:101: warning: format ‘%d’ expects argument of type ‘int’, but argument 3 has type ‘long long unsigned int’ [-Wformat=]
X ++;Y = X * 1LL * (X+1) / 2;for(i = 1; i <= N-X-2; i ++) /*V[++T] = i;*/fprintf(fout,"%d ", i);Z = K-Y; Z = N-X-1+Z; fprintf(fout,"%d ", Z);for(i = N; i >= N-X-1; i --)if(i == Z) continue;else fprintf(fout,"%d ", i);/*for(i = 1; i <= N; i ++) /*fout << V[i] << " ";*//*fprintf(fout,"%d ", V[i]);*/return;}int main(){CodeExpert();return 0;}
^
user.cpp:4:146: warning: format ‘%d’ expects argument of type ‘int’, but argument 3 has type ‘long long unsigned int’ [-Wformat=]
X ++;Y = X * 1LL * (X+1) / 2;for(i = 1; i <= N-X-2; i ++) /*V[++T] = i;*/fprintf(fout,"%d ", i);Z = K-Y; Z = N-X-1+Z; fprintf(fout,"%d ", Z);for(i = N; i >= N-X-1; i --)if(i == Z) continue;else fprintf(fout,"%d ", i);/*for(i = 1; i <= N; i ++) /*fout << V[i] << " ";*//*fprintf(fout,"%d ", V[i]);*/return;}int main(){CodeExpert();return 0;}
^
user.cpp:4:266: warning: format ‘%d’ expects argument of type ‘int’, but argument 3 has type ‘long long unsigned int’ [-Wformat=]
X ++;Y = X * 1LL * (X+1) / 2;for(i = 1; i <= N-X-2; i ++) /*V[++T] = i;*/fprintf(fout,"%d ", i);Z = K-Y; Z = N-X-1+Z; fprintf(fout,"%d ", Z);for(i = N; i >= N-X-1; i --)if(i == Z) continue;else fprintf(fout,"%d ", i);/*for(i = 1; i <= N; i ++) /*fout << V[i] << " ";*//*fprintf(fout,"%d ", V[i]);*/return;}int main(){CodeExpert();return 0;}
^
user.cpp:3:265: warning: ignoring return value of ‘int fscanf(FILE*, const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
/*ifstream fin ("farfurii.in" );*/FILE *fin = fopen("farfurii.in", "r");/*ofstream fout("farfurii.out");*/FILE *fout = fopen("farfurii.out","w");unsigned long long N, M, i, j, K, ok, minim, T, X, Y, Z;void CodeExpert(){/*fin >> N >> K;*/fscanf(fin, "%d%d", &N, &K); X = 1;while((X+1) * 1LL * (X+2) <= K * 2)
^
| Test |
Timp executie |
Memorie folosita |
Mesaj |
Punctaj/test |
| 1 | 0ms | 248kb | OK! | 10 |
| 2 | 0ms | 248kb | OK! | 10 |
| 3 | 0ms | 252kb | OK! | 10 |
| 4 | 0ms | 252kb | OK! | 10 |
| 5 | 0ms | 252kb | OK! | 10 |
| 6 | 0ms | 248kb | OK! | 10 |
| 7 | 4ms | 256kb | OK! | 10 |
| 8 | 8ms | 248kb | OK! | 10 |
| 9 | 12ms | 256kb | OK! | 10 |
| 10 | 20ms | 252kb | Wrong answer! | 0 |
| Punctaj total | 90 |