Problem choose2eat1
User YSH2020
Submission Time 2025-12-26 15:16:35
Score 0
Max Time N/A
Max Memory N/A

Compile Error

choose2eat1.cpp: In function ‘int main()’:
choose2eat1.cpp:36:12: error: conflicting declaration ‘long long int a’
36 | long long a=0;
| ^
choose2eat1.cpp:28:6: note: previous declaration as ‘long long int a [n]’
28 | int a[n]; for (int i = 0; i < n; i++) cin >> a[i];
| ^
choose2eat1.cpp:39:46: error: incompatible types in assignment of ‘long long int’ to ‘long long int [n]’
39 | a+=join(i.second.first, i.second.second)*i.first;
| ^~~~~