Borderou de evaluare (job #3263680)

Utilizator Nasa1004Ema Nicole Gheorghe Nasa1004 Data 15 decembrie 2024 22:59:01
Problema Sortnet Status done
Runda Arhiva de probleme Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp: In function 'void add(int)': main.cpp:23:22: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare] 23 | for(int i = 0; i < ans.size(); i++) { | ~~^~~~~~~~~~~~ main.cpp: In function 'int main()': main.cpp:43:23: warning: comparison of integer expressions of different signedness: 'int' and 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} [-Wsign-compare] 43 | while(pos < s.size() - 1) { | ~~~~^~~~~~~~~~~~~~ main.cpp:64:22: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare] 64 | for(int i = 1; i < ans.size(); i++) { | ~~^~~~~~~~~~~~ main.cpp:79:24: error: invalid types '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type {aka int}[int]' for array subscript 79 | curr[j][bit] = curr[j - 1][per]; ///SCHIMBAM DE AICI IN JOS | ^ main.cpp:79:43: error: invalid types '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type {aka int}[int]' for array subscript 79 | curr[j][bit] = curr[j - 1][per]; ///SCHIMBAM DE AICI IN JOS | ^ main.cpp:80:24: error: invalid types '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type {aka int}[int]' for array subscript 80 | curr[j][per] = curr[j - 1][bit]; | ^ main.cpp:80:43: error: invalid types '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type {aka int}[int]' for array subscript 80 | curr[j][per] = curr[j - 1][bit]; | ^ main.cpp:84:24: error: invalid types '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type {aka int}[int]' for array subscript 84 | curr[j][bit] = curr[j - 1][bit]; | ^ main.cpp:84:43: error: invalid types '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type {aka int}[int]' for array subscript 84 | curr[j][bit] = curr[j - 1][bit]; | ^ main.cpp:85:24: error: invalid types '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type {aka int}[int]' for array subscript 85 | curr[j][per] = curr[j - 1][per]; | ^ main.cpp:85:43: error: invalid types '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type {aka int}[int]' for array subscript 85 | curr[j][per] = curr[j - 1][per]; | ^ main.cpp:91:14: error: no match for 'operator==' (operand types are 'std::string' {aka 'std::__cxx11::basic_string<char>'} and '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type' {aka 'int'}) 91 | if(s == curr[m]) In file included from /usr/include/c++/12.2.1/string:41, from /usr/include/c++/12.2.1/bits/locale_classes.h:40, from /usr/include/c++/12.2.1/bits/ios_base.h:41, from /usr/include/c++/12.2.1/ios:42, from /usr/include/c++/12.2.1/ostream:38, from /usr/include/c++/12.2.1/iostream:39, from main.cpp:1: /usr/include/c++/12.2.1/bits/allocator.h:219:5: note: candidate: 'template<class _T1, class _T2> constexpr bool std::operator==(const allocator<_CharT>&, const allocator<_T2>&)' (reversed) 219 | operator==(const allocator<_T1>&, const allocator<_T2>&) | ^~~~~~~~ /usr/include/c++/12.2.1/bits/allocator.h:219:5: note: template argument deduction/substitution failed: main.cpp:91:23: note: mismatched types 'const std::allocator<_CharT>' and '__gnu_cxx::__alloc_traits<std::allocator<int>, int>::value_type' {aka 'int'} 91 | if(s == curr[m]) Non zero exit status: 1

Ceva nu functioneaza?