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 "robots.h"
#include <bits/stdc++.h>
using namespace std;
int putaway(int a, int b, int t, int x[], int y[], int w[], int s[]) {
if (a == 0){
if (min(s[0], s[1]) < min(y[0], y[1]) && max(s[0], s[1]) < max(y[0], y[1])) return 1;
else if (max(s[0], s[1]) >= max(y[0], y[1])) return -1;
else return 2;
} else if (a == 1){
if ((w[0] < x[0] && s[1] < y[0]) || (w[1] < x[0] && s[0] < y[0])) return 1;
else if ((w[0] >= x[0] && s[0] >= y[0]) || (w[1] >= x[0] && s[1] >= y[0])) return -1;
else return 2;
} else{
if (min(w[0], w[1]) < min(x[0], x[1]) && max(w[0], w[1]) < max(x[0], x[1])) return 1;
else if (max(w[0], w[1]) >= max(x[0], x[1])) return -1;
else return 2;
}
}
# | 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... |