# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
511134 | Salama | 최댓값 (tutorial2) | C++14 | 0 ms | 0 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;
long long z=0;
long long GetMax(long long x,long long q[]){ x-=1; if(x>0) {if(q[x]>q[x-1]){ z=max(z,q[x]); return GetMax(x,q);} else { z=max(z,q[x-1]); return GetMax(x-1,q);}}
return z;
}