Borderou de evaluare (job #2918937)

Utilizator BlaugranasEnal Gemaledin Blaugranas Data 14 august 2022 09:48:14
Problema Scara 3 Status done
Runda Arhiva de probleme Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp:7:1: error: '::main' must return 'int' 7 | void main() | ^~~~ main.cpp: In function 'int main()': main.cpp:8:2: error: 'ifstream' was not declared in this scope; did you mean 'std::ifstream'? 8 | {ifstream fi("scara3.in"); | ^~~~~~~~ | std::ifstream In file included from /usr/include/c++/10/ios:38, from /usr/include/c++/10/istream:38, from /usr/include/c++/10/sstream:38, from /usr/include/c++/10/complex:45, from /usr/include/c++/10/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:54, from main.cpp:1: /usr/include/c++/10/iosfwd:162:34: note: 'std::ifstream' declared here 162 | typedef basic_ifstream<char> ifstream; | ^~~~~~~~ main.cpp:9:2: error: 'ofstream' was not declared in this scope; did you mean 'std::ofstream'? 9 | ofstream fo("scara3.out"); | ^~~~~~~~ | std::ofstream In file included from /usr/include/c++/10/ios:38, from /usr/include/c++/10/istream:38, from /usr/include/c++/10/sstream:38, from /usr/include/c++/10/complex:45, from /usr/include/c++/10/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:54, from main.cpp:1: /usr/include/c++/10/iosfwd:165:34: note: 'std::ofstream' declared here 165 | typedef basic_ofstream<char> ofstream; | ^~~~~~~~ main.cpp:12:2: error: 'fi' was not declared in this scope; did you mean 'i'? 12 | fi>>n; | ^~ | i main.cpp:15:13: error: 'MAXLONG' was not declared in this scope 15 | cost[i][j]=MAXLONG; | ^~~~~~~ main.cpp:25:32: error: 'cout' was not declared in this scope; did you mean 'std::cout'? 25 | if (! fi.good() || x>100) cout<<"apa incorect\n"; | ^~~~ | std::cout In file included from /usr/include/x86_64-linux-gnu/c++/10/bits/stdc++.h:75, from main.cpp:1: /usr/include/c++/10/iostream:61:18: note: 'std::cout' declared here 61 | extern ostream cout; /// Linked to standard output | ^~~~ main.cpp:35:32: error: 'cout' was not declared in this scope; did you mean 'std::cout'? 35 | if (! fi.good() || y>100) cout<<"baut incorect\n"; Non zero exit status: 1

Ceva nu functioneaza?