Submission #511134

# Submission time Handle Problem Language Result Execution time Memory
511134 2022-01-15T08:35:24 Z Salama 최댓값 (tutorial2) C++14
Compilation error
0 ms 0 KB
#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;
} 

Compilation message

/usr/bin/ld: /tmp/ccasM4X3.o: in function `main':
grader.cpp:(.text.startup+0xaa): undefined reference to `GetMax(int, int*)'
collect2: error: ld returned 1 exit status