| # | Time | Username | Problem | Language | Result | Execution time | Memory |
|---|---|---|---|---|---|---|---|
| 203019 | arnold518 | 산악 구조대 (JOI13_mountain) | C++14 | 18 ms | 940 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>
#include "grader.h"
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
int n, m;
void Rescue(int N, int M, int cy, int cx, int val)
{
n=N, m=M;
int i, j;
int y=1, x=cx;
while(y<=cy && 1<=x)
{
int t=Measure(y, x);
if(t==val)
{
Pinpoint(y, x);
return;
}
else if(t<val) y++;
else if(t>val) x--;
}
y=1, x=cx;
while(y<=cy && x<=m)
{
int t=Measure(y, x);
if(t==val)
{
Pinpoint(y, x);
return;
}
else if(t<val) y++;
else if(t>val) x++;
}
y=n, x=cx;
while(cy<=y && 1<=x)
{
int t=Measure(y, x);
if(t==val)
{
Pinpoint(y, x);
return;
}
else if(t<val) y--;
else if(t>val) x--;
}
y=n, x=cx;
while(cy<=y && x<=m)
{
int t=Measure(y, x);
if(t==val)
{
Pinpoint(y, x);
return;
}
else if(t<val) y--;
else if(t>val) x++;
}
}Compilation message (stderr)
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
| # | Verdict | Execution time | Memory | Grader output |
|---|---|---|---|---|
| Fetching results... | ||||
