Borderou de evaluare (job #1568959)
Utilizator | Data | 14 ianuarie 2016 21:18:20 | |
---|---|---|---|
Problema | Zimeria | Status | done |
Runda | Arhiva de probleme | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp: In function ‘void citire()’:
user.cpp:22:23: warning: format ‘%s’ expects argument of type ‘char*’, but argument 2 has type ‘char (*)[15]’ [-Wformat=]
scanf("%s",&cuvord);
^
user.cpp:23:38: warning: array subscript has type ‘char’ [-Wchar-subscripts]
for (i=0; i<=11; i++) v[cuvord[i]]=i+1;
^
user.cpp:25:32: warning: format ‘%s’ expects argument of type ‘char*’, but argument 2 has type ‘char (*)[7]’ [-Wformat=]
scanf("%s",&a[i].cuvant);
^
user.cpp: In function ‘bool cmp(cuvantul, cuvantul)’:
user.cpp:36:27: warning: array subscript has type ‘char’ [-Wchar-subscripts]
if (v[cuvantul1[i]]<v[cuvantul2[i]]) return 1;
^
user.cpp:36:43: warning: array subscript has type ‘char’ [-Wchar-subscripts]
if (v[cuvantul1[i]]<v[cuvantul2[i]]) return 1;
^
user.cpp:37:36: warning: array subscript has type ‘char’ [-Wchar-subscripts]
else if (v[cuvantul1[i]]>v[cuvantul2[i]]) return 0;
^
user.cpp:37:52: warning: array subscript has type ‘char’ [-Wchar-subscripts]
else if (v[cuvantul1[i]]>v[cuvantul2[i]]) return 0;
^
user.cpp: In function ‘int main()’:
user.cpp:49:39: error: could not convert ‘(char*)(& cuvord)’ from ‘char*’ to ‘cuvantul’
printf("%d",cmp(cuvord,a[2].cuvant));
^
user.cpp: In function ‘void citire()’:
user.cpp:20:19: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&p);
^
user.cpp:21:19: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d",&n);
^
user.cpp:22:24: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%s",&cuvord);
^
user.cpp:25:33: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%s",&a[i].cuvant);
^
user.cpp: In function ‘int main()’:
user.cpp:43:36: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("zimeria.in","r",stdin);
^
user.cpp:44:38: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result]
freopen("zimeria.out","w",stdout);
^
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !