Borderou de evaluare (job #3164649)

Utilizator Manolea_Teodor_StefanManolea Teodor Stefan Manolea_Teodor_Stefan Data 3 noiembrie 2023 23:51:53
Problema Problema Damelor Status done
Runda Arhiva educationala Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp:10:5: error: 'int index' redeclared as different kind of entity 10 | int index; | ^~~~~ In file included from /usr/include/string.h:462, from /usr/include/c++/12.2.1/cstring:42, from /usr/include/c++/12.2.1/x86_64-pc-linux-gnu/bits/stdc++.h:48, from main.cpp:1: /usr/include/strings.h:61:1: note: previous declaration 'const char* index(const char*, int)' 61 | index (const char *__s, int __c) __THROW | ^~~~~ main.cpp: In function 'void solve()': main.cpp:12:22: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare] 12 | for(int i = 1; i < pnt_arr.size(); i++){ | ~~^~~~~~~~~~~~~~~~ main.cpp:24:10: error: no post-increment operator for type 24 | index++; | ^~ main.cpp: In function 'bool verify()': main.cpp:29:22: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare] 29 | for(int i = 0; i < pnt_arr.size() - 1; i++) | ~~^~~~~~~~~~~~~~~~~~~~ main.cpp: In function 'void combine()': main.cpp:49:31: warning: comparison of integer expressions of different signedness: 'std::vector<int>::size_type' {aka 'long unsigned int'} and 'int' [-Wsign-compare] 49 | if(pnt_arr.size() == n){ | ~~~~~~~~~~~~~~~^~~~ main.cpp:38:10: warning: unused variable 'end_task' [-Wunused-variable] 38 | bool end_task = false; | ^~~~~~~~ main.cpp: In function 'int main()': main.cpp:74:15: error: no match for 'operator<<' (operand types are 'std::basic_ostream<char>' and '<unresolved overloaded function type>') 74 | fout<<'\n'<<index; | ~~~~~~~~~~^~~~~~~ In file included from /usr/include/c++/12.2.1/istream:39, from /usr/include/c++/12.2.1/sstream:38, from /usr/include/c++/12.2.1/complex:45, from /usr/include/c++/12.2.1/ccomplex:39, from /usr/include/c++/12.2.1/x86_64-pc-linux-gnu/bits/stdc++.h:54: /usr/include/c++/12.2.1/ostream:108:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(__ostream_type& (*)(__ostream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]' 108 | operator<<(__ostream_type& (*__pf)(__ostream_type&)) | ^~~~~~~~ /usr/include/c++/12.2.1/ostream:108:36: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'std::basic_ostream<char>::__ostream_type& (*)(std::basic_ostream<char>::__ostream_type&)' {aka 'std::basic_ostream<char>& (*)(std::basic_ostream<char>&)'} 108 | operator<<(__ostream_type& (*__pf)(__ostream_type&)) | ~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/12.2.1/ostream:117:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(__ios_type& (*)(__ios_type&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>; __ios_type = std::basic_ios<char>]' 117 | operator<<(__ios_type& (*__pf)(__ios_type&)) | ^~~~~~~~ /usr/include/c++/12.2.1/ostream:117:32: note: no known conversion for argument 1 from '<unresolved overloaded function type>' to 'std::basic_ostream<char>::__ios_type& (*)(std::basic_ostream<char>::__ios_type&)' {aka 'std::basic_ios<char>& (*)(std::basic_ios<char>&)'} 117 | operator<<(__ios_type& (*__pf)(__ios_type&)) | ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~ /usr/include/c++/12.2.1/ostream:127:7: note: candidate: 'std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::ios_base& (*)(std::ios_base&)) [with _CharT = char; _Traits = std::char_traits<char>; __ostream_type = std::basic_ostream<char>]' Non zero exit status: 1

Ceva nu functioneaza?