# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
677194 | sofija6 | Job Scheduling (CEOI12_jobs) | C++14 | 304 ms | 27320 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
#define ll int
#define MAXM 1000002
using namespace std;
ll n,d,m;
pair<ll,ll> a[MAXM];
bool Check(ll x)
{
for (ll i=1;i<=x;i++)
{
ll cur=1;
for (ll j=1;j<=m;j+=x)
{
if (cur<a[j].first)
cur=a[j].first;
if (cur-a[j].first>d)
return false;
cur++;
}
}
return true;
}
int main()
{
ios::sync_with_stdio(false); cin.tie(0); cout.tie(0);
cin >> n >> d >> m;
for (ll i=1;i<=m;i++)
{
cin >> a[i].first;
a[i].second=i;
컴파일 시 표준 에러 (stderr) 메시지
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |