| # | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
|---|---|---|---|---|---|---|---|
| 1363923 | inesfi | Island Hopping (JOI24_island) | C++20 | 2 ms | 416 KiB |
#include "island.h"
#include<bits/stdc++.h>
using namespace std;
const int TAILLEMAXI=302;
bool dejavu[TAILLEMAXI];
int pere[TAILLEMAXI];
void q(int a, int b, int c){
cout<<"query "<<a<<" "<<b<<" rep "<<c<<endl;
}
void solve(int n, int nbquest_max) {
dejavu[1] = true;
for (int i=1;i<n;i++){
int ec = query(1, i);
//q(1, i, ec);
dejavu[ec] = true;
if (pere[ec] == 0){
int vois = query(ec, 1);
//q(ec, 1, vois);
int compt = 1;
while (!dejavu[vois]){
pere[vois] = ec;
compt ++;
vois = query(ec, compt);
//q(ec, compt, vois);
}
pere[ec] = vois;
}
}
for (int i=2;i<=n;i++){
//cerr<<i<<" "<<pere[i]<<endl;
answer(i, pere[i]);
}
}| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
| # | 결과 | 실행 시간 | 메모리 | 채점기 출력 |
|---|---|---|---|---|
| 결과를 불러오는 중입니다… | ||||
