Submission #1209907

#TimeUsernameProblemLanguageResultExecution timeMemory
1209907LIACave (IOI13_cave)C++17
Compilation error
0 ms0 KiB
#include "cave.h" #include <bits/stdc++.h> using namespace std; typedef int ll; typedef tuple<ll, ll, ll> plll; typedef vector<plll> vplll; typedef pair<ll, ll> pll; typedef vector<ll> vll; typedef vector<pll> vpll; typedef vector<vector<pll>> vvpll; typedef vector<vector<ll>> vvll; typedef vector<bool> vb; typedef vector<vector<bool>> vvb; #define loop(i, s, e) for (ll i = (s); i < (e); ++i) #define loopr(i, e, s) for (ll i = (e)-1; i >= (s); --i) #define all(a) a.begin(), a.end() const ll inf = 1e9 + 7; void exploreCave(int n) { vll ans(n),ans1(n); loop(i,0,n) { ans[i] = i; ans1[i] = 1; } answer(ans1, ans); }

Compilation message (stderr)

cave.cpp: In function 'void exploreCave(int)':
cave.cpp:25:10: error: cannot convert 'vll' {aka 'std::vector<int>'} to 'int*'
   25 |   answer(ans1, ans);
      |          ^~~~
      |          |
      |          vll {aka std::vector<int>}
In file included from cave.cpp:1:
cave.h:9:17: note:   initializing argument 1 of 'void answer(int*, int*)'
    9 | void answer(int S[], int D[]);
      |             ~~~~^~~