Submission #657594

#TimeUsernameProblemLanguageResultExecution timeMemory
657594TimDeeA Difficult(y) Choice (BOI21_books)C++17
Compilation error
0 ms0 KiB
#include"books.h" #include <bits/stdc++.h> using namespace std; void solve(int n, int k, int A, int s) { if (s!=n) return; vector<int> a(n); for (int i=0; i<n; ++i) a[i]=skim(i+1); if (k==3) { for (int i=0; i<n; ++i) { for (int j=i+1; j<n; ++j) { int l=j+1, r=n; while (l<r) { int mid=(l+r)>>1; if (a[i]+a[j]+a[mid]<A) l=mid+1; else r=mid; } if (a[i]+a[j]+a[r]<=2*A) { answer({i+1,j+1,r+1}); return; } } } impossible(); } }

Compilation message (stderr)

/usr/bin/ld: /tmp/ccqPIvYK.o: in function `main':
grader.cpp:(.text.startup+0x83): undefined reference to `solve(int, int, long long, int)'
collect2: error: ld returned 1 exit status