Mai intai trebuie sa te autentifici.
Borderou de evaluare (job #2327497)
| Utilizator | Data | 24 ianuarie 2019 19:14:37 | |
|---|---|---|---|
| Problema | Permutari | Status | done |
| Runda | Arhiva de probleme | Compilator | cpp-64 | Vezi sursa |
| Scor | 100 | ||
Raport evaluator
Compilare:
main.cpp: In function 'int main()':
main.cpp:3:78: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)', declared with attribute warn_unused_result [-Wunused-result]
int a[Nmax][Nmax];int n,k;int main(){int t,i,j,l;freopen("perm.in","r",stdin);freopen("perm.out","w",stdout);scanf("%d %d", &n,&k);a[1][0]=1;for (i=2;i<=n;++i)for (j=i;j>=1;--j)for (t=0,l=0;l<=400;++l){t=(a[j][l]=a[j][l]*(i-1)+a[j-1][l]+t)/10;a[j][l]%=10;}for (i=400;(--i) && a[k][i]==0;);while(i>=0){printf("%d",a[k][i]);i--;}return 0;}
^
main.cpp:3:109: warning: ignoring return value of 'FILE* freopen(const char*, const char*, FILE*)', declared with attribute warn_unused_result [-Wunused-result]
int a[Nmax][Nmax];int n,k;int main(){int t,i,j,l;freopen("perm.in","r",stdin);freopen("perm.out","w",stdout);scanf("%d %d", &n,&k);a[1][0]=1;for (i=2;i<=n;++i)for (j=i;j>=1;--j)for (t=0,l=0;l<=400;++l){t=(a[j][l]=a[j][l]*(i-1)+a[j-1][l]+t)/10;a[j][l]%=10;}for (i=400;(--i) && a[k][i]==0;);while(i>=0){printf("%d",a[k][i]);i--;}return 0;}
^
main.cpp:3:131: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
int a[Nmax][Nmax];int n,k;int main(){int t,i,j,l;freopen("perm.in","r",stdin);freopen("perm.out","w",stdout);scanf("%d %d", &n,&k);a[1][0]=1;for (i=2;i<=n;++i)for (j=i;j>=1;--j)for (t=0,l=0;l<=400;++l){t=(a[j][l]=a[j][l]*(i-1)+a[j-1][l]+t)/10;a[j][l]%=10;}for (i=400;(--i) && a[k][i]==0;);while(i>=0){printf("%d",a[k][i]);i--;}return 0;}
^
| Test | Timp executie | Memorie folosita | Mesaj | Punctaj/test |
|---|---|---|---|---|
| 1 | 2ms | 131kb | Ok! | 10 |
| 2 | 3ms | 131kb | Ok! | 10 |
| 3 | 13ms | 262kb | Ok! | 10 |
| 4 | 30ms | 393kb | Ok! | 10 |
| 5 | 79ms | 524kb | Ok! | 10 |
| 6 | 2ms | 131kb | Ok! | 10 |
| 7 | 11ms | 262kb | Ok! | 10 |
| 8 | 71ms | 393kb | Ok! | 10 |
| 9 | 15ms | 262kb | Ok! | 10 |
| 10 | 62ms | 393kb | Ok! | 10 |
| Punctaj total | 100 | |||
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !
