Borderou de evaluare (job #2785478)
Utilizator | Data | 18 octombrie 2021 19:17:09 | |
---|---|---|---|
Problema | Componente biconexe | Status | done |
Runda | Arhiva educationala | Compilator | cpp-64 | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp: In function 'int main()':
main.cpp:3:17: error: cannot convert 'const char*' to 'FILE*'
3 | #define IN_FILE "biconex.in"
| ^~~~~~~~~~~~
| |
| const char*
main.cpp:18:12: note: in expansion of macro 'IN_FILE'
18 | fscanf(IN_FILE, "%d%d", n, m);
| ^~~~~~~
In file included from /usr/include/c++/10/cstdio:42,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:46,
from main.cpp:1:
/usr/include/stdio.h:391:37: note: initializing argument 1 of 'int fscanf(FILE*, const char*, ...)'
391 | extern int fscanf (FILE *__restrict __stream,
| ~~~~~~~~~~~~~~~~~^~~~~~~~
main.cpp:3:17: error: cannot convert 'const char*' to 'FILE*'
3 | #define IN_FILE "biconex.in"
| ^~~~~~~~~~~~
| |
| const char*
main.cpp:22:16: note: in expansion of macro 'IN_FILE'
22 | fscanf(IN_FILE, "%d%d", x, y);
| ^~~~~~~
In file included from /usr/include/c++/10/cstdio:42,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:46,
from main.cpp:1:
/usr/include/stdio.h:391:37: note: initializing argument 1 of 'int fscanf(FILE*, const char*, ...)'
391 | extern int fscanf (FILE *__restrict __stream,
| ~~~~~~~~~~~~~~~~~^~~~~~~~
main.cpp:4:18: error: cannot convert 'const char*' to 'FILE*'
4 | #define OUT_FILE "biconex.out"
| ^~~~~~~~~~~~~
| |
| const char*
main.cpp:30:13: note: in expansion of macro 'OUT_FILE'
30 | fprintf(OUT_FILE, "%d\n", no_components);
| ^~~~~~~~
In file included from /usr/include/c++/10/cstdio:42,
from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:46,
from main.cpp:1:
/usr/include/stdio.h:326:38: note: initializing argument 1 of 'int fprintf(FILE*, const char*, ...)'
326 | extern int fprintf (FILE *__restrict __stream,
| ~~~~~~~~~~~~~~~~~^~~~~~~~
main.cpp:4:18: error: cannot convert 'const char*' to 'FILE*'
4 | #define OUT_FILE "biconex.out"
| ^~~~~~~~~~~~~
| |
| const char*
main.cpp:35:21: note: in expansion of macro 'OUT_FILE'
35 | fprintf(OUT_FILE, "%d ", component_element);
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !