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

#define len(v) (int)v.size()
#define all(v) v.begin(), v.end()

using namespace std;
using ll = long long int;
using ld = long double;

mt19937 rnd(1984);

vector<vector<int>> solve(int n) {
    vector<int> p(n);
    iota(all(p), 0);
    shuffle(all(p), rnd);
    vector<vector<int>> ans;
    for (int i = 0; i + 2 < n; i += 3) {
        ans.push_back({p[i], p[i + 1], p[i + 2]});
    }
    return ans;
}