# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
486649 | alextodoran | Navigation 2 (JOI21_navigation2) | C++17 | 0 ms | 196 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
/**
____ ____ ____ ____ ____
||a |||t |||o |||d |||o ||
||__|||__|||__|||__|||__||
|/__\|/__\|/__\|/__\|/__\|
**/
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int East = 0;
const int West = 1;
const int South = 2;
const int North = 3;
const int Finish = 4;
#include "Anna.h"
void SetFlag (int r, int c, int value);
void Anna (int N, int K, vector <int> R, vector <int> C)
{
for(int r = 0; r < N; r++)
for(int c = 0; c < N; c++)
{
int value = 0;
for(int t = 0; t < K; t++)
{
value *= 5;
if(r == R[t] && c == C[t])
value += Finish;
else if(r < R[t])
value += South;
else if(r > R[t])
value += North;
else if(c < C[t])
value += East;
else if(c > C[t])
value += West;
}
SetFlag(r, c, value + 1);
}
}
/**
____ ____ ____ ____ ____
||a |||t |||o |||d |||o ||
||__|||__|||__|||__|||__||
|/__\|/__\|/__\|/__\|/__\|
**/
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
const int East = 0;
const int West = 1;
const int South = 2;
const int North = 3;
const int Finish = 4;
#include "Bruno.h"
vector <int> Bruno (int K, vector <int> value)
{
int mat[3][3];
for(int i = 0; i < 3; i++)
for(int j = 0; j < 3; j++)
mat[i][j] = value[i * 3 + j - 1];
vector <int> sol (K);
for(int t = K - 1; t >= 0; t--)
{
sol[t] = mat[1][1] % 5;
mat[1][1] /= 5;
}
return sol;
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |