# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
197774 | Malomalomalomalo | Watching (JOI13_watching) | C++14 | 348 ms | 16248 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
#define gmin(x,y) x=min(x,y)
#define all(c) c.begin(), c.end()
using namespace std;
const int N = 2e3 + 5;
int dp[N][N];
const int inf = 1e9;
int main(){
cin.tie(0);
cout.tie(0);
ios_base::sync_with_stdio(0);
int n,p,q;
cin >> n >> p >> q;
gmin(p,n);
gmin(q,n);
vector<int> pos(n+1);
for(int i = 1;i <= n; ++i){
cin >> pos[i];
}
sort(all(pos));
int l = 1, r = 1e9, ans = inf;
while(l <= r){
int m = l + (r-l)/2;
for(int i = 0;i <= n; ++i){
for(int j = 0;j <= n; ++j){
dp[i][j] = inf;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |