Problem foodchain
User Masquared
Submission Time 2026-11-27 16:57:22
Score 0
Max Time N/A
Max Memory N/A

Compile Error

foodchain.cpp:5:5: error: ‘long long int div’ redeclared as different kind of entity
5 | int div = 1000000009;
| ^~~
In file included from /usr/include/c++/9/bits/std_abs.h:38,
from /usr/include/c++/9/cmath:47,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:41,
from foodchain.cpp:1:
/usr/include/stdlib.h:852:14: note: previous declaration ‘div_t div(int, int)’
852 | extern div_t div (int __numer, int __denom)
| ^~~
foodchain.cpp: In function ‘int main()’:
foodchain.cpp:8:13: error: invalid operands of types ‘long long int’ and ‘<unresolved overloaded function type>’ to binary ‘operator%’
8 | cout << (A % div)*(B % div)*(C % div)*(D%div)*(E%div);
| ~~^~~~~
foodchain.cpp:8:23: error: invalid operands of types ‘long long int’ and ‘<unresolved overloaded function type>’ to binary ‘operator%’
8 | cout <<