Problem permutationgrid
User WouldIWas
Submission Time 2025-05-13 13:46:31
Score 0
Max Time N/A
Max Memory N/A

Compile Error

permutationgrid.cpp: In function ‘int main()’:
permutationgrid.cpp:15:6: error: redeclaration of ‘long long int min’
15 | int min;
| ^~~
permutationgrid.cpp:9:6: note: ‘long long int min’ previously declared here
9 | int min;
| ^~~
permutationgrid.cpp:18:38: error: ‘min’ cannot be used as a function
18 | min = min(arr[i][j], arr[i+1][j+1]);
| ^
permutationgrid.cpp:23:23: error: ‘j’ was not declared in this scope
23 | next = min(arr[i+1][j], arr[i-1][j], arr[i][j+1], arr[i][j-1])
| ^
permutationgrid.cpp:23:64: error: ‘min’ cannot be used as a function
23 | next = min(arr[i+1][j], arr[i-1][j], arr[i][j+1], arr[i][j-1])
| ^
permutationgrid.cpp:27:3: error: ‘else’ without a previous ‘if’
27 | else {
| ^~~~
permutationgrid.cpp:28:11: erro