Problem exponentiate
User thatlycheeoolongdrink
Submission Time 2024-03-04 17:22:35
Score 0
Max Time N/A
Max Memory N/A

Compile Error

exponentiate.cpp: In function ‘int main()’:
exponentiate.cpp:8:10: error: no match for ‘operator^’ (operand types are ‘std::basic_ostream<char>’ and ‘int’)
8 | cout<<a^b%m;
| ~~~~~~~^~~~
| | |
| | int
| std::basic_ostream<char>
exponentiate.cpp:8:10: note: candidate: ‘operator^(int, int)’ <built-in>
8 | cout<<a^b%m;
| ~~~~~~~^~~~
exponentiate.cpp:8:10: note: no known conversion for argument 1 from ‘std::basic_ostream<char>’ to ‘int’
In file included from /usr/include/c++/9/ios:42,
from /usr/include/c++/9/ostream:38,
from /usr/include/c++/9/iostream:39,
from exponentiate.cpp:1:
/usr/include/c++/9/bits/ios_base.h:91:3: note: candidate: ‘constexpr std::_Ios_Fmtflags std::operator^(std::_Ios_Fmtflags, std::_Ios_Fmtflags)’
91 | operator^(_Ios_Fmtflags __a, _Ios_Fmtflags __b)