Borderou de evaluare (job #2202520)

Utilizator cezar.dimoiuDimoiu Cezar Gabriel cezar.dimoiu Data 8 mai 2018 22:44:08
Problema A+B Status done
Runda Arhiva de probleme Compilator c | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.c: In function ‘main’: user.c:4:32: error: ‘rt’ undeclared (first use in this function) FILE in = fopen("adunare.in", rt); ^~ user.c:4:32: note: each undeclared identifier is reported only once for each function it appears in user.c:5:34: error: ‘wt’ undeclared (first use in this function) FILE out = fopen("adunare.out", wt); ^~ user.c:8:9: error: incompatible type for argument 1 of ‘fscanf’ fscanf(in, "%d", a); ^~ In file included from /usr/include/features.h:367:0, from /usr/include/stdio.h:27, from user.c:1: /usr/include/stdio.h:443:12: note: expected ‘FILE * restrict {aka struct _IO_FILE * restrict}’ but argument is of type ‘FILE {aka struct _IO_FILE}’ extern int __REDIRECT (fscanf, (FILE *__restrict __stream, ^ user.c:9:9: error: incompatible type for argument 1 of ‘fscanf’ fscanf(in, "%d", b); ^~ In file included from /usr/include/features.h:367:0, from /usr/include/stdio.h:27, from user.c:1: /usr/include/stdio.h:443:12: note: expected ‘FILE * restrict {aka struct _IO_FILE * restrict}’ but argument is of type ‘FILE {aka struct _IO_FILE}’ extern int __REDIRECT (fscanf, (FILE *__restrict __stream, ^ user.c:11:10: error: incompatible type for argument 1 of ‘fprintf’ fprintf(out, "%d", a+b); ^~~ In file included from /usr/include/stdio.h:936:0, from user.c:1: /usr/include/bits/stdio2.h:95:1: note: expected ‘FILE * restrict {aka struct _IO_FILE * restrict}’ but argument is of type ‘FILE {aka struct _IO_FILE}’ fprintf (FILE *__restrict __stream, const char *__restrict __fmt, ...) ^~~~~~~ user.c:12:9: error: incompatible type for argument 1 of ‘fclose’ fclose(in); ^~ In file included from user.c:1:0: /usr/include/stdio.h:237:12: note: expected ‘FILE * {aka struct _IO_FILE *}’ but argument is of type ‘FILE {aka struct _IO_FILE}’ extern int fclose (FILE *__stream); ^~~~~~ user.c:13:9: error: incompatible type for argument 1 of ‘fclose’ fclose(out); ^~~ In file included from user.c:1:0: /usr/include/stdio.h:237:12: note: expected ‘FILE * {aka struct _IO_FILE *}’ but argument is of type ‘FILE {aka struct _IO_FILE}’ extern int fclose (FILE *__stream); ^~~~~~

Ceva nu functioneaza?