# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
199804 | Gamma | Pismo (COCI18_pismo) | C++14 | 62 ms | 376 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
using namespace std;
int N, n, mx = -(1e9) - 7, mn = (1e9) + 7;
int main()
{
cin >> N;
for(int i = 0; i < N; i++)
{
cin >> n;
mx = max(mx, n);
mn = min(mn, n);
}
printf("%d\n", mx - mn);
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |