Problem dogfood
User qwertyuiop
Submission Time 2026-05-29 15:59:52
Score 0
Max Time N/A
Max Memory N/A

Compile Error

dogfood.cpp: In function ‘int main()’:
dogfood.cpp:47:32: error: invalid initialization of reference of type ‘std::vector<long long int>&’ from expression of type ‘long long int [N]’
47 | cout << maxSubarraySum(a, N);
| ^
dogfood.cpp:21:33: note: in passing argument 1 of ‘long long int maxSubarraySum(std::vector<long long int>&)’
21 | int maxSubarraySum(vector<int> &arr) {
| ~~~~~~~~~~~~~^~~