#include "triangles.h"
#include <bits/stdc++.h>
#define ll long long
#define ld long double
using namespace std;

vector<vector<int>> solve(int n) {
    vector<int> arr(n, 0);
    int x = 0;
    int y = 1;
    int ned = 2;
    for (int i = 3; i < n; i++) {
        vector<Triangle> arr1;
        vector<Triangle> arr2;
        arr1.push_back(Triangle(x, y, ned));
        arr2.push_back(Triangle(x, y, i));
        int f = compare(arr1, arr2);
        if (f == -1) {
            ned = i;
        }
    }
    y = 1;
    for (int i = 2; i < n; i++) {
        if (i == ned) {
            continue;
        }
        vector<Triangle> arr1;
        vector<Triangle> arr2;
        arr1.push_back(Triangle(x, i, ned));
        arr2.push_back(Triangle(x, y, ned));
        int f = compare(arr1, arr2);
        if (f == -1) {
            y = i;
        }
    }
    for (int i = 1; i < n; i++) {
        if (i == ned || i == y) {
            continue;
        }
        vector<Triangle> arr1;
        vector<Triangle> arr2;
        arr1.push_back(Triangle(i, y, ned));
        arr2.push_back(Triangle(x, y, ned));
        int f = compare(arr1, arr2);
        if (f == -1) {
            x = i;
        }
    }
    vector<vector<int>> arr1(1, vector<int> ());
    arr1[0].push_back(x);
    arr1[0].push_back(y);
    arr1[0].push_back(ned);
    return arr1;
}