Problem potatosalad
User Ast8ine
Submission Time 2026-02-16 12:23:13
Score 0
Max Time N/A
Max Memory N/A

Compile Error

potatosalad.cpp: In function ‘int main()’:
potatosalad.cpp:8:15: error: expected ‘;’ before ‘:’ token
8 | cin >> n >> d:
| ^
| ;
potatosalad.cpp:10:19: error: expected ‘;’ before ‘<’ token
10 | for (int i = 0, i < d, i++){
| ^~
| ;
potatosalad.cpp:10:20: error: expected primary-expression before ‘<’ token
10 | for (int i = 0, i < d, i++){
| ^
potatosalad.cpp:10:28: error: expected ‘;’ before ‘)’ token
10 | for (int i = 0, i < d, i++){
| ^
| ;
potatosalad.cpp:11:10: error: ‘potato’ was not declared in this scope
11 | cin >> potato[i];
| ^~~~~~
potatosalad.cpp:13:35: error: ‘arr’ was not declared in this scope
13 | int* max_ptr = max_element(begin(arr), end(arr));
|