Submission #1258560

#TimeUsernameProblemLanguageResultExecution timeMemory
1258560haiphong5g0Triple Peaks (IOI25_triples)C++20
Compilation error
0 ms0 KiB
//#include "souvenirs.h" #include <bits/stdc++.h> #define task "TEST" #define task2 "A" #define pl pair<ll, ll> #define pf push_front #define pb push_back #define pob pop_back #define pof pop_front #define mp make_pair #define fi first #define se second #define FOR(i, a, b, c) for (int i=a; i<=b; i+=c) #define FORE(i, a, b, c) for (int i=a; i>=b; i+=c) using namespace std; using ll = long long; using Knowledge = pair<vector<int>, ll>; using ull = unsigned long long; const int Mod = 998244353; const int maxn = 3e5; const ll Inf = 1e16; ll n, a, s; vector<int> P, T; struct Coupon { ll p, num; ll pos; bool operator > (Coupon other) const { return p*num*other.num + other.p*other.num < other.p*other.num*num + p*num; }; }; vector<Coupon> C[5]; ll Fix(ll& i, ll& j, ll& k, ll& h, ll pos, ll add) { ll v; if (pos == 1) i += add, v = i; if (pos == 2) j += add, v = j; if (pos == 3) k += add, v = k; if (pos == 4) h += add, v = h; return v; } vector<int> max_coupons(int s, vector<int> P, vector<int> T) { vector<Coupon> S; vector<int> res; FOR(i, 0, P.size()-1, 1) S.pb({P[i], T[i], i}); sort(S.begin(), S.end(), greater<Coupon>()); FOR(i, 0, P.size()-1, 1) res.pb(S[i].pos); return res; }

Compilation message (stderr)

/usr/bin/ld: /tmp/ccoPnWRx.o: in function `main':
grader.cpp:(.text.startup+0x18a): undefined reference to `construct_range(int, int)'
/usr/bin/ld: grader.cpp:(.text.startup+0x37b): undefined reference to `count_triples(std::vector<int, std::allocator<int> >)'
collect2: error: ld returned 1 exit status