제출 #607531

#제출 시각아이디문제언어결과실행 시간메모리
607531MohamedFaresNebili철로 (IOI14_rail)C++14
컴파일 에러
0 ms0 KiB
#include <bits/stdc++.h>
/// #pragma GCC optimize ("Ofast")
/// #pragma GCC target ("avx2")
/// #pragma GCC optimize("unroll-loops")

            using namespace std;

            using ll = long long;
            using ld = long double;

            #define ff first
            #define ss second
            #define pb push_back
            #define all(x) (x).begin(), (x).end()
            #define lb lower_bound

            const int MOD = 998244353;

            void findLocation(int n, int first, int location[], int stype[]) {
                location[0] = first;
                stype[0] = 1;
                for(int l = 1; l < n; l++)
                    stype[l] = 2, location[l] = first + getDistance(0, l);
            }

컴파일 시 표준 에러 (stderr) 메시지

rail.cpp: In function 'void findLocation(int, int, int*, int*)':
rail.cpp:23:57: error: 'getDistance' was not declared in this scope
   23 |                     stype[l] = 2, location[l] = first + getDistance(0, l);
      |                                                         ^~~~~~~~~~~