Submission #250125

#TimeUsernameProblemLanguageResultExecution timeMemory
250125linear00000최댓값 (tutorial2)C++14
Compilation error
0 ms0 KiB
int GetMax(int n, int[] A) { int a = -1; for (int i=0; i<n; i++) if (a > A[i]) a = A[i]; return a; }

Compilation message (stderr)

tutorial2.cpp:1:25: error: expected ',' or '...' before 'A'
 int GetMax(int n, int[] A) {
                         ^
tutorial2.cpp: In function 'int GetMax(int, int*)':
tutorial2.cpp:3:35: error: 'A' was not declared in this scope
   for (int i=0; i<n; i++) if (a > A[i]) a = A[i];
                                   ^