Submission #570295

#TimeUsernameProblemLanguageResultExecution timeMemory
570295FirasMesbehRainforest Jumps (APIO21_jumps)C++17
Compilation error
0 ms0 KiB
#include <bits/stdc++.h> using namespace std; int n, a[N]; void init(int N, vector<int> H) { for (int i = 1; i <= N; ++ i) { a[i] = H[i - 1]; } } int minimum_jumps(int A, int B, int C, int D) { return (C - B); }

Compilation message (stderr)

jumps.cpp:3:10: error: 'N' was not declared in this scope
    3 | int n, a[N];
      |          ^
jumps.cpp: In function 'void init(int, std::vector<int>)':
jumps.cpp:7:9: error: 'a' was not declared in this scope
    7 |         a[i] = H[i - 1];
      |         ^