# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
309366 | amunduzbaev | 로봇 (IOI13_robots) | C++14 | 1 ms | 416 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include "robots.h"
//#include "grader.cpp"
#include <bits/stdc++.h>
using namespace std;
const int N=1e4+5;
int putaway(int wet, int smt, int T, int we[], int sm[], int wt[], int st[]) {
int t=T;
sort(we,we+wet);
sort(sm,sm+smt);
for(int i=0;i<t;i++){
if(wet&&smt){
if(wt[i]>we[wet-1]&&st[i]>sm[smt-1]) return -1;
}else if(wet){
if(wt[i]>we[wet-1]) return -1;
}else
if(st[i]>sm[smt-1]) return -1;
}
if(wet&&smt)
if((we[0]>=wt[1]&&sm[0]>=st[0])||(we[0]>=wt[0]&&sm[0]>=st[1])) return 1;
if(wet==t)
if(wt[0]<=we[1]&&wt[1]<=we[0]||wt[1]<=we[1]&&wt[0]<=we[0]) return 1;
if(smt==t)
if(st[0]<=sm[1]&&st[1]<=sm[0]||st[1]<=sm[1]&&st[0]<=sm[0]) return 1;
return 2;
}
컴파일 시 표준 에러 (stderr) 메시지
# | 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... |