#include "bits/stdc++.h"
#define puba push_back
#define mapa make_pair
#define ff first
#define ss second
#define bend(_x) (_x).begin(), (_x).end()
#define szof(_x) ((int) (_x).size())
#define TASK_NAME "division"

using namespace std;
typedef long long ll;
typedef pair <int, int> pii;

int n;

int main() {        
    freopen(TASK_NAME ".in", "r", stdin);
    freopen(TASK_NAME ".out", "w", stdout);

    scanf("%d", &n);

    int tmp = n / 3;

    ll best = 8e18;
    tuple<int, int, int> mem = make_tuple(-1, -1, -1);

    for (int i = -100; i <= 100; ++i) {
        for (int j = -100; j <= 100; ++j) {
            for (int k = -100; k <= 100; ++k) {
                int a = tmp + i;
                int b = tmp + j;
                int c = tmp + k;
                cerr << a * a + b * b + c * c << endl;
                if (1 <= a && 1 <= b && 1 <= c && a < b && b < c && a + b + c == n) {
                    if (best > a * a + b * b + c * c) {
                        best = a * a + b * b + c * c;
                        mem = make_tuple(a, b, c);
                    }
                }
            }
        }
    }

    cout << get<0>(mem) << " " << get<1>(mem) << " " << get<2>(mem) << endl;

    return 0;
}