Borderou de evaluare (job #638322)
Utilizator |
|
IP | ascuns |
---|---|---|---|
Problemă | Formula 1 (clasa a 6-a) | Compilator | c-32 |
Rundă | Concurs 13 cursuri de performanță | IQ Academy | clasa a 6-a | Status | evaluat |
Dată | 4 mar. 2022 18:56:17 | Scor | 0 |
Raport evaluator
Eroare de compilare:
main.c: In function 'main':
main.c:9:10: error: incompatible types when assigning to type 'FILE' from type 'FILE *'
9 | fis2=fopen("formula1.out", "w");
| ^~~~~
main.c:17:18: error: incompatible type for argument 1 of 'fprintf'
17 | fprintf (fis2, "%lld", (k+k-1)*(k+k-1));
| ^~~~
| |
| FILE
In file included from /usr/include/stdio.h:866,
from main.c:1:
/usr/include/bits/stdio2.h:103:27: note: expected 'FILE * restrict' but argument is of type 'FILE'
103 | fprintf (FILE *__restrict __stream, const char *__restrict __fmt, ...)
| ~~~~~~~~~~~~~~~~~^~~~~~~~
main.c:27:22: error: incompatible type for argument 1 of 'fprintf'
27 | fprintf (fis2, "%lld", a*2+1);
| ^~~~
| |
| FILE
In file included from /usr/include/stdio.h:866,
from main.c:1:
/usr/include/bits/stdio2.h:103:27: note: expected 'FILE * restrict' but argument is of type 'FILE'
103 | fprintf (FILE *__restrict __stream, const char *__restrict __fmt, ...)
| ~~~~~~~~~~~~~~~~~^~~~~~~~
main.c:31:22: error: incompatible type for argument 1 of 'fprintf'
31 | fprintf (fis2, "%lld", ((int)sqrt(a*2-1)-2)*2+1);
| ^~~~
| |
| FILE
In file included from /usr/include/stdio.h:866,
from main.c:1:
/usr/include/bits/stdio2.h:103:27: note: expected 'FILE * restrict' but argument is of type 'FILE'
103 | fprintf (FILE *__restrict __stream, const char *__restrict __fmt, ...)
| ~~~~~~~~~~~~~~~~~^~~~~~~~
main.c:14:5: warning: ignoring return value of 'fscanf' declared with attribute 'warn_unused_result' [-Wunused-result]
14 | fscanf (fis1, "%d\n%d%d", &c,&k,&n);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~