Borderou de evaluare (job #682083)

Utilizator avatar adrianb Badan Adrian adrianb IP ascuns
Problemă Tabela Compilator cpp-32
Rundă Arhiva de probleme Status evaluat
Dată 15 dec. 2022 13:02:41 Scor 0

Raport evaluator

Eroare de compilare: main.cpp: In function 'int main()': main.cpp:10:13: error: no match for 'operator^' (operand types are 'std::basic_ostream<char>::__ostream_type' {aka 'std::basic_ostream<char>'} and 'long long int') 10 | fout<<a xor b; | ~~~~~~~ ^~~ ~ | | | | | long long int | std::basic_ostream<char>::__ostream_type {aka std::basic_ostream<char>} main.cpp:10:13: note: candidate: 'operator^(int, long long int)' (built-in) 10 | fout<<a xor b; | ~~~~~~~~^~~~~ main.cpp:10:13: 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/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/i686-pc-linux-gnu/bits/stdc++.h:66, from main.cpp:1: /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/bitset:1453:5: note: candidate: 'template<unsigned int _Nb> std::bitset<_Nb> std::operator^(const std::bitset<_Nb>&, const std::bitset<_Nb>&)' 1453 | operator^(const bitset<_Nb>& __x, const bitset<_Nb>& __y) _GLIBCXX_NOEXCEPT | ^~~~~~~~ /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/bitset:1453:5: note: template argument deduction/substitution failed: main.cpp:10:17: note: 'std::basic_ostream<char>::__ostream_type' {aka 'std::basic_ostream<char>'} is not derived from 'const std::bitset<_Nb>' 10 | fout<<a xor b; | ^ In file included from /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/valarray:603, from /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/i686-pc-linux-gnu/bits/stdc++.h:95, from main.cpp:1: /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/bits/valarray_after.h:410:5: note: candidate: 'template<class _Dom1, class _Dom2> std::_Expr<std::__detail::_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>&)' 410 | _DEFINE_EXPR_BINARY_OPERATOR(^, struct std::__bitwise_xor) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/bits/valarray_after.h:410:5: note: template argument deduction/substitution failed: main.cpp:10:17: note: 'std::basic_ostream<char>::__ostream_type' {aka 'std::basic_ostream<char>'} is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>' 10 | fout<<a xor b; | ^ In file included from /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/valarray:603, from /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/i686-pc-linux-gnu/bits/stdc++.h:95, from main.cpp:1: /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/bits/valarray_after.h:410:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_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&)' 410 | _DEFINE_EXPR_BINARY_OPERATOR(^, struct std::__bitwise_xor) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/bits/valarray_after.h:410:5: note: template argument deduction/substitution failed: main.cpp:10:17: note: 'std::basic_ostream<char>::__ostream_type' {aka 'std::basic_ostream<char>'} is not derived from 'const std::_Expr<_Dom1, typename _Dom1::value_type>' 10 | fout<<a xor b; | ^ In file included from /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/valarray:603, from /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/i686-pc-linux-gnu/bits/stdc++.h:95, from main.cpp:1: /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/bits/valarray_after.h:410:5: note: candidate: 'template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__bitwise_xor, std::_Constant, std::_Expr, typename _Dom::value_type, _Dom>, typename std::__fun<std::__bitwise_xor, typename _Dom1::value_type>::result_type> std::operator^(const typename _Dom::value_type&, const std::_Expr<_Dom1, typename _Dom1::value_type>&)' 410 | _DEFINE_EXPR_BINARY_OPERATOR(^, struct std::__bitwise_xor) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/lib/gcc/i686-pc-linux-gnu/11.3.0/include/g++-v11/bits/valarray_after.h:410:5: note: template argument deduction/substitution failed: main.cpp:10:17: note: mismatched types 'const std::_Expr<_Dom1, typename _Dom1::value_type>' and 'long long int' 10 | fout<<a xor b; | ^