Borderou de evaluare (job #2637968)

Utilizator alex.prohnitchiAlex Prohnitchi alex.prohnitchi Data 26 iulie 2020 01:14:04
Problema Tabela Status done
Runda Arhiva de probleme Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp: In function 'int main()': main.cpp:33:15: error: no match for 'operator^' (operand types are 'std::basic_ostream<char>::__ostream_type {aka std::basic_ostream<char>}' and 'll {aka long long int}') cout << (a-1)^(b-1) << '\n'; ~~~~~~~~~~~~~^~~~~~~~~~~~~~ main.cpp:33:15: note: candidate: operator^(int, ll {aka long long int}) <built-in> main.cpp:33:15: note: no known conversion for argument 1 from 'std::basic_ostream<char>::__ostream_type {aka std::basic_ostream<char>}' to 'int' In file included from /usr/include/c++/6/ios:42:0, from /usr/include/c++/6/istream:38, from /usr/include/c++/6/sstream:38, from /usr/include/c++/6/complex:45, from /usr/include/c++/6/ccomplex:39, from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:52, from main.cpp:2: /usr/include/c++/6/bits/ios_base.h:91:3: note: candidate: constexpr std::_Ios_Fmtflags std::operator^(std::_Ios_Fmtflags, std::_Ios_Fmtflags) operator^(_Ios_Fmtflags __a, _Ios_Fmtflags __b) ^~~~~~~~ /usr/include/c++/6/bits/ios_base.h:91:3: note: no known conversion for argument 1 from 'std::basic_ostream<char>::__ostream_type {aka std::basic_ostream<char>}' to 'std::_Ios_Fmtflags' /usr/include/c++/6/bits/ios_base.h:133:3: note: candidate: constexpr std::_Ios_Openmode std::operator^(std::_Ios_Openmode, std::_Ios_Openmode) operator^(_Ios_Openmode __a, _Ios_Openmode __b) ^~~~~~~~ /usr/include/c++/6/bits/ios_base.h:133:3: note: no known conversion for argument 1 from 'std::basic_ostream<char>::__ostream_type {aka std::basic_ostream<char>}' to 'std::_Ios_Openmode' /usr/include/c++/6/bits/ios_base.h:173:3: note: candidate: constexpr std::_Ios_Iostate std::operator^(std::_Ios_Iostate, std::_Ios_Iostate) operator^(_Ios_Iostate __a, _Ios_Iostate __b) ^~~~~~~~ /usr/include/c++/6/bits/ios_base.h:173:3: note: no known conversion for argument 1 from 'std::basic_ostream<char>::__ostream_type {aka std::basic_ostream<char>}' to 'std::_Ios_Iostate' In file included from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:66:0, from main.cpp:2: /usr/include/c++/6/bitset:1443:5: note: candidate: template<long unsigned int _Nb> std::bitset<_Nb> std::operator^(const std::bitset<_Nb>&, const std::bitset<_Nb>&) operator^(const bitset<_Nb>& __x, const bitset<_Nb>& __y) _GLIBCXX_NOEXCEPT ^~~~~~~~ /usr/include/c++/6/bitset:1443:5: note: template argument deduction/substitution failed: main.cpp:33:25: note: 'std::basic_ostream<char>::__ostream_type {aka std::basic_ostream<char>}' is not derived from 'const std::bitset<_Nb>' cout << (a-1)^(b-1) << '\n'; ^~~~ In file included from /usr/include/c++/6/valarray:587:0, from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:95, from main.cpp:2: /usr/include/c++/6/bits/valarray_after.h:407:5: note: candidate: template<class _Dom1, class _Dom2> std::_Expr<std::_BinClos<std::__bitwise_xor, std::_Expr, std::_Expr, _Dom1, _Dom2>, typename std::__fun<std::__bitwise_xor, typename _Dom1::value_type>::result_type> std::operator^(const std::_Expr<_Dom1, typename _Dom1::value_type>&, const std::_Expr<_Dom2, typename _Dom2::value_type>&) _DEFINE_EXPR_BINARY_OPERATOR(^, __bitwise_xor) ^ /usr/include/c++/6/bits/valarray_after.h:407:5: note: template argument deduction/substitution failed: main.cpp:33:25: note: 'std::basic_ostream<char>::__ostream_type {aka std::basic_ostream<char>}' is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>' cout << (a-1)^(b-1) << '\n'; ^~~~ In file included from /usr/include/c++/6/valarray:587:0, from /usr/include/x86_64-linux-gnu/c++/6/bits/stdc++.h:95, from main.cpp:2: /usr/include/c++/6/bits/valarray_after.h:407:5: note: candidate: template<class _Dom> std::_Expr<std::_BinClos<std::__bitwise_xor, std::_Expr, std::_Constant, _Dom, typename _Dom::value_type>, typename std::__fun<std::__bitwise_xor, typename _Dom1::value_type>::result_type> std::operator^(const std::_Expr<_Dom1, typename _Dom1::value_type>&, const typename _Dom::value_type&) _DEFINE_EXPR_BINARY_OPERATOR(^, __bitwise_xor) ^ Non zero exit status: 1

Ceva nu functioneaza?