Problem fibo_ex
User shenshiqi
Submission Time 2026-04-02 14:58:14
Score 0
Max Time N/A
Max Memory N/A

Compile Error

fibo_ex.cpp: In function ‘std::pair<BigInt, BigInt> fib(long long int)’:
fibo_ex.cpp:68:18: error: no match for ‘operator*’ (operand types are ‘BigInt’ and ‘int’)
68 | BigInt c = a * 0 + a; // placeholder, we'll replace multiplication with addition-only formulas
| ~ ^ ~
| | |
| | int
| BigInt
In file included from /usr/include/c++/9/ccomplex:39,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:54,
from fibo_ex.cpp:1:
/usr/include/c++/9/complex:391:5: note: candidate: ‘template<class _Tp> std::complex<_Tp> std::operator*(const std::complex<_Tp>&, const std::complex<_Tp>&)’
391 | operator*(const complex<_Tp>& __x, const complex<_Tp>& __y)
| ^~~~~~~~
/usr/include/c++/9/complex:391:5: note: template argument deduction/substitution failed:
fibo_ex.cpp:68:20: