# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
971840 | 2024-04-29T11:26:59 Z | Sunbae | Stove (JOI18_stove) | C++17 | 0 ms | 344 KB |
#include <bits/stdc++.h> using namespace std; signed main(){ int n, k; scanf("%d %d", &n, &k); int mx = INT_MIN, mn = INT_MAX; for(int i = 0, x; i<n; ++i){ scanf("%d", &x); mx = max(mx, x); mn = min(mn, x); } printf("%d", mx - mn - k + 1); }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 0 ms | 344 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 0 ms | 344 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 0 ms | 344 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |