#include "islands.h"
#include <variant>
#include <vector>
using namespace std;
#define pb push_back
variant<bool, vector<int>> find_journey(int N, int M, vector<int> U, vector<int> V) {
	if(N==2){
		// subtask 1
		vector<int> bthere, bback;
		for(int i=0; i<M; i++){
			if(U[i]==0 && V[i]==1){
				bthere.pb(i);
			} else{
				bback.pb(i);
			}
		}
		if(bthere.size()>1 && bback.size()>1){
			vector<int> answer = {bthere[0], bback[0], bthere[1], bback[1], bback[0], bthere[0], bback[1], bthere[1]};
			return answer;
		} else{
			return false;
		}
	}
	return false;	
}
| # | 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... |