# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1798 | caffeinism7 | 최댓값 (tutorial2) | C++98 | 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 <stdio.h>
int GetMax(int N, int A[]){
int main(void){
int N, A[3000];
scanf("%d", &N);
for(int i = 1; i <= N; i ++){
scanf("%d", &A[i]);
}
printf("%d", GetMax(N, A));
return 0;
}
int max = 0;
for(int i=1; i<=N; i++){
if(max < A[i]){
max = A[i];
}
}
return max;
}