Borderou de evaluare (job #2130187)
Utilizator | Data | 13 februarie 2018 15:23:35 | |
---|---|---|---|
Problema | Numere Prime | Status | done |
Runda | Arhiva de probleme | Compilator | c | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.c: In function ‘main’:
user.c:15:31: warning: variable ‘rez’ set but not used [-Wunused-but-set-variable]
int i, k, j = 3, h, g, b, rez;
^
user.c: At top level:
user.c:75:5: warning: data definition has no type or storage class
f1 = fopen("prim.out", "wb");
^
user.c:75:5: warning: type defaults to ‘int’ in declaration of ‘f1’ [-Wimplicit-int]
user.c:75:5: error: conflicting types for ‘f1’
user.c:74:12: note: previous declaration of ‘f1’ was here
FILE * f1;
^
user.c:75:10: warning: initialization makes integer from pointer without a cast [-Wint-conversion]
f1 = fopen("prim.out", "wb");
^
user.c:75:10: error: initializer element is not constant
user.c:76:12: error: expected declaration specifiers or ‘...’ before ‘&’ token
fwrite(&rez,sizeof(int),1, f1);
^
user.c:76:17: error: expected declaration specifiers or ‘...’ before ‘sizeof’
fwrite(&rez,sizeof(int),1, f1);
^
user.c:76:29: error: expected declaration specifiers or ‘...’ before numeric constant
fwrite(&rez,sizeof(int),1, f1);
^
user.c:76:32: error: expected declaration specifiers or ‘...’ before ‘f1’
fwrite(&rez,sizeof(int),1, f1);
^
user.c:77:5: warning: data definition has no type or storage class
fclose(f1);
^
user.c:77:5: warning: type defaults to ‘int’ in declaration of ‘fclose’ [-Wimplicit-int]
user.c:77:5: warning: parameter names (without types) in function declaration
user.c:78:5: error: expected identifier or ‘(’ before ‘return’
return 0;
^
user.c:79:1: error: expected identifier or ‘(’ before ‘}’ token
}
^
user.c: In function ‘main’:
user.c:17:5: warning: ignoring return value of ‘fread’, declared with attribute warn_unused_result [-Wunused-result]
fread(&k,sizeof(k),1,f);
^
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !