#include using namespace std; #define ll long long #define rep(i, n) for (int i = 0; i < (n); i++) #define P pair int main() { int N; cin >> N; int a = 0, b = 0, c = 0; int flag = 0; rep(i, 31) { if (N & (1 << i)) { if (flag % 3 == 1) { a += 1 << i; b += 1 << i; } else if (flag % 3 == 2) { b += 1 << i; c += 1 << i; } else { c += 1 << i; a += 1 << i; } flag++; } } if (a != 0 && b != 0 && c != 0) { cout << a << " " << b << " " << c << endl; } else { cout << -1 << " " << -1 << " " << -1 << endl; } }