| # | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
|---|---|---|---|---|---|---|---|
| 718490 | nihaddhuseynli | Robots (IOI13_robots) | C++14 | 185 ms | 15296 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include "robots.h"
#include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
int putaway(int A, int B, int T, int X[], int Y[], int W[], int S[]) {
ll ans;
ll check[T+5];
sort(X,X+A);
sort(Y,Y+B);
sort(W,W+T);
sort(S,S+T);
memset(check,0,sizeof(check));
ll cnt = upper_bound(W,W+T,X[A-1])-W;
ll cnt1 = upper_bound(S,S+T,Y[B-1])-S;
if(W[cnt-1]>=X[A-1] && S[cnt1]>=Y[B-1])
{
return -1;
}
if(A==1 && B==1)
{
ans=1;
}
else
{
if(X[0]>min(W[0],W[1]) && X[1]>max(W[0],W[1]))
{
ans=1;
}
else if(X[1]>min(W[0],W[1]) && X[0]>max(W[0],W[1]))
{
ans=1;
}
else if(Y[0]>min(S[0],S[1]) && Y[1]>max(S[0],S[1]))
{
ans=1;
}
else if(Y[1]>min(S[0],S[1]) && Y[0]>max(S[0],S[1]))
{
ans=1;
}
else
{
ans=2;
}
}
return ans;
}
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
