#include "bits/stdc++.h"
#include "triangles.h"

#pragma GCC optimize("03,unroll-loops")

#define all(x) x.begin(), x.end()
#define rall(x) x.rbegin(), x.rend()
#define len(x) ((int)x.size())

using namespace std;
using ll = long long;
using ld = long double;
using T = Triangle;

// int compare(const std::vector<Triangle>& left, const std::vector<Triangle>& right);

vector<vector<int>> solve(int n) {
    vector<vector<int>> ans(2);
    vector<vector<T>> w;
    for (int i = 0; i < n; ++i) {
        for (int j = i + 1; j < n; ++j) {
            w.emplace_back();
            for (int k = 0; k < n; ++k) {
                if (k != i && k != j) {
                    w.back().emplace_back({i, j, k});
                }
            }
        }
    }
    for (int i = 0; i < len(w); ++i) {
        for (int j = i + 1; j < len(w); ++j) {
            auto q = compare(w[i], w[j]);
            if (!q) {
                ans[0] = {w[i][0].i, w[i][0].j, w[i][0].k};
                ans[1] = {w[i][1].i, w[i][1].j, w[i][1]|.k};
                return ans;
            }
        }
    }
    return ans;
}