| # | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
|---|---|---|---|---|---|---|---|
| 1235779 | Aisha | Maxcomp (info1cup18_maxcomp) | C++20 | 1095 ms | 8264 KiB |
#include "bits/stdc++.h"
using namespace std;
#define int long long
signed main() {
int n, m;
cin >> n >> m;
vector <vector <int>> a(n + 1, vector <int> (m + 1));
for (int i = 1; i <= n; i ++) {
for (int j = 1; j <= m; j ++) cin >> a[i][j];
}
int ans = -1;
for (int i = 1; i <= n; i ++) {
for (int j = 1; j <= m; j ++) {
for (int x = 1; x <= n; x ++) {
for (int y = 1; y <= m; y ++) {
ans = max(ans, abs(a[i][j] - a[x][y]) - abs(i - x) - abs(j - y) - 1);
}
}
}
}
cout << ans << endl;
return 0;
}| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
