# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
260065 | MiricaMatei | Job Scheduling (CEOI12_jobs) | C++17 | 355 ms | 17272 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>
using namespace std;
const int MAXN = 100005;
const int MAXM = 1000005;
pair<int, int> v[MAXM];
bool ok(int n, int d, int m, int k) {
int j = 1;
for (int i = 1; i <= n; ++i) {
int k1 = k;
while (j <= m && v[j].first <= i && k1 > 0) {
if (i - v[j].first > d)
return 0;
j++;
k1--;
}
}
return 1;
}
int main() {
//freopen("date.in", "r", stdin);
//freopen("date.out", "w", stdout);
int n, d, m;
scanf("%d%d%d", &n, &d, &m);
for (int i = 1; i <= m; ++i) {
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |