Submission #328905

#TimeUsernameProblemLanguageResultExecution timeMemory
328905opukittpceno_hhrGap (APIO16_gap)C++17
Compilation error
0 ms0 KiB
#include "gap.h" #include <iostream> #include <vector> #include <map> #include <set> #include <queue> #include <algorithm> #include <string> #include <cmath> #include <cstdio> #include <iomanip> #include <fstream> #include <cassert> #include <cstring> #include <unordered_set> #include <unordered_map> #include <numeric> #include <ctime> #include <bitset> #include <complex> #include <chrono> #include <random> #include <functional> using namespace std; typedef long long ll; const ll INF = 1e18 + 239; ll findGap(int T, int N) { assert(T == 1);s ll F, S; MinMax((ll)0, INF, &F, &S); vector<ll> v; while (F != -1 && F != S) { v.push_back(F); v.push_back(S); ll nF, nS; if (F + 1 > S - 1) break; MinMax(F + 1, S - 1, &nF, &nS); F = nF; S = nS; } if (F == S && F != -1) v.push_back(F); sort(v.begin(), v.end()); assert((int)v.size() == N); ll ans = 0; for (int i = 0; i + 1 < N; i++) { ans = max(ans, v[i + 1] - v[i]); } return ans; }

Compilation message (stderr)

gap.cpp: In function 'll findGap(int, int)':
gap.cpp:33:20: error: 's' was not declared in this scope
   33 |     assert(T == 1);s
      |                    ^
gap.cpp:35:25: error: 'F' was not declared in this scope
   35 |     MinMax((ll)0, INF, &F, &S);
      |                         ^
gap.cpp:35:29: error: 'S' was not declared in this scope
   35 |     MinMax((ll)0, INF, &F, &S);
      |                             ^