#include "triangles.h"

#include <bits/stdc++.h>
using namespace std;

std::vector<std::vector<int>> solve(int n) {
    vector<int> ord = {0, 1, 2, 3};
    do {
        if (compare({Triangle(ord[0], ord[1], ord[2]), Triangle(ord[1], ord[2], ord[3])},
                    {Triangle(ord[0], ord[2], ord[3]), Triangle(ord[0], ord[1], ord[3])}) == 0) {
            return {{0, 1, 2}, {1, 2, 3}};
        }
    } while (next_permutation(ord.begin(), ord.end()));
    vector<int> cur = {0, 1, 2};
    ord = {0, 1, 2, 3};
    do {
        if (compare({Triangle(cur[0], cur[1], cur[2])},
                    {Triangle(ord[0], ord[1], ord[2])}) == -1) {
            cur = {ord[0], ord[1], ord[2]};
        }
    } while (next_permutation(ord.begin(), ord.end()));
    return {cur};
}
