#include "ramen.h"
#include <bits/stdc++.h>
using namespace std;
vector<int> adj[410];
void Ramen(int N) {
int mx = 0, mn = 0;
for(int i = 1; i < N; ++i){
if(Compare(mx, i) == -1){
adj[i].push_back(mx);
// cerr << "dbg : " << i << ' ' << mx << '\n';
mx = i;
}else{
adj[mx].push_back(i);
// cerr << "dbg : " << mx << ' ' << i << '\n';
}
}
queue<int> q;
q.push(mx);
vector<int> leaves;
while(!q.empty()){
int u = q.front(); q.pop();
cerr << u << ' ';
bool leaf = 1;
for(auto v : adj[u]){
leaf = 0;
q.push(v);
}
if(leaf) leaves.push_back(u);
}
mn = leaves.front();
for(int i = 1; i < leaves.size(); ++i){
if(Compare(mn, leaves[i]) == 1){
mn = leaves[i];
}
}
Answer(mn, mx);
}