Problem stepgame
User yqiiiiiii
Submission Time 2026-09-17 15:05:07
Score 0
Max Time N/A
Max Memory N/A

Compile Error

stepgame.cpp: In function ‘int main()’:
stepgame.cpp:21:39: error: expected ‘)’ before ‘;’ token
21 | premax[i] = max(premax[i-1], psum[i];
| ~ ^
| )
stepgame.cpp:25:39: error: expected ‘)’ before ‘;’ token
25 | ans = min(ans, psum[r] - premax[r-1];
| ~ ^
| )
stepgame.cpp:27:13: error: expected ‘}’ at end of input
27 | cout << ans;
| ^
stepgame.cpp:3:11: note: to match this ‘{’
3 | int main(){
| ^