QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#473052 | #8049. Equal Sums | egypt_ioi2024b_05 | Compile Error | / | / | C++20 | 4.2kb | 2024-07-11 21:29:08 | 2024-07-11 21:29:09 |
Due to the privacy settings of the submitter, you are not allowed to view this code.
Details
answer.code: In function ‘int main()’: answer.code:90:114: error: no match for ‘operator%’ (operand types are ‘std::bitset<32>’ and ‘const int’) 90 | x[i][j] = (k < sz1 ? pre[k] : (xr[i].to_ulong() - j < sz1 ? suf[xr[i].to_ulong() - j] : pre[sz1-1])) % mod; | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~ | | | | std::bitset<32> const int In file included from /usr/include/c++/13/valarray:605, from /usr/include/x86_64-linux-gnu/c++/13/bits/stdc++.h:166, from answer.code:12: /usr/include/c++/13/bits/valarray_after.h:409:5: note: candidate: ‘template<class _Dom1, class _Dom2> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Expr, std::_Expr, _Dom1, _Dom2>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const _Expr<_Dom1, typename _Dom1::value_type>&, const _Expr<_Dom2, typename _Dom2::value_type>&)’ 409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/13/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed: answer.code:90:116: note: ‘std::bitset<32>’ is not derived from ‘const std::_Expr<_Dom1, typename _Dom1::value_type>’ 90 | x[i][j] = (k < sz1 ? pre[k] : (xr[i].to_ulong() - j < sz1 ? suf[xr[i].to_ulong() - j] : pre[sz1-1])) % mod; | ^~~ /usr/include/c++/13/bits/valarray_after.h:409:5: note: candidate: ‘template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Expr, std::_Constant, _Dom, typename _Dom::value_type>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const _Expr<_Dom1, typename _Dom1::value_type>&, const typename _Dom::value_type&)’ 409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/13/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed: answer.code:90:116: note: ‘std::bitset<32>’ is not derived from ‘const std::_Expr<_Dom1, typename _Dom1::value_type>’ 90 | x[i][j] = (k < sz1 ? pre[k] : (xr[i].to_ulong() - j < sz1 ? suf[xr[i].to_ulong() - j] : pre[sz1-1])) % mod; | ^~~ /usr/include/c++/13/bits/valarray_after.h:409:5: note: candidate: ‘template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Constant, std::_Expr, typename _Dom::value_type, _Dom>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const typename _Dom::value_type&, const _Expr<_Dom1, typename _Dom1::value_type>&)’ 409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/13/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed: answer.code:90:116: note: mismatched types ‘const std::_Expr<_Dom1, typename _Dom1::value_type>’ and ‘const int’ 90 | x[i][j] = (k < sz1 ? pre[k] : (xr[i].to_ulong() - j < sz1 ? suf[xr[i].to_ulong() - j] : pre[sz1-1])) % mod; | ^~~ /usr/include/c++/13/bits/valarray_after.h:409:5: note: candidate: ‘template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_Expr, std::_ValArray, _Dom, typename _Dom::value_type>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operator%(const _Expr<_Dom1, typename _Dom1::value_type>&, const valarray<typename _Dom::value_type>&)’ 409 | _DEFINE_EXPR_BINARY_OPERATOR(%, struct std::__modulus) | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ /usr/include/c++/13/bits/valarray_after.h:409:5: note: template argument deduction/substitution failed: answer.code:90:116: note: ‘std::bitset<32>’ is not derived from ‘const std::_Expr<_Dom1, typename _Dom1::value_type>’ 90 | x[i][j] = (k < sz1 ? pre[k] : (xr[i].to_ulong() - j < sz1 ? suf[xr[i].to_ulong() - j] : pre[sz1-1])) % mod; | ^~~ /usr/include/c++/13/bits/valarray_after.h:409:5: note: candidate: ‘template<class _Dom> std::_Expr<std::__detail::_BinClos<std::__modulus, std::_ValArray, std::_Expr, typename _Dom::value_type, _Dom>, typename std::__fun<std::__modulus, typename _Dom1::value_type>::result_type> std::operato...