Submission #560115

# Submission time Handle Problem Language Result Execution time Memory
560115 2022-05-11T05:06:52 Z armashka Rainforest Jumps (APIO21_jumps) C++17
Compilation error
0 ms 0 KB
int n, a[200005];

void init(int N, int[] H) {
	n = N;
	for (int i = 1; i <= n; ++ i) {
		a[i] = H[i - 1];
	}
	return;
}

int minimum_jumps(int A, int B, int C, int D) {
	return 0;
} 

Compilation message

jumps.cpp:3:24: error: expected ',' or '...' before 'H'
    3 | void init(int N, int[] H) {
      |                        ^
jumps.cpp: In function 'void init(int, int*)':
jumps.cpp:6:10: error: 'H' was not declared in this scope
    6 |   a[i] = H[i - 1];
      |          ^