#pragma GCC optimize("Ofast")
#include <bits/stdc++.h>
using namespace std;
typedef long long int ll;
typedef unsigned long long int ull;

mt19937_64 rng(chrono::steady_clock::now().time_since_epoch().count());
ll myRand(ll B) {
    return (ull)rng() % B;
}

int main() {
    cin.tie(nullptr);
    ios::sync_with_stdio(false);
    pair<ll,ll> p;
    for (ll a = 1e8; a <= 1e9; a++) {
        ll c1 = -4*a;
        ll c2 = a*a-1;
        if (c1*c1 - 4*c2 < 0) continue;
        ll b = -c1+round(sqrt(c1*c1 - 4*c2));
        if (b%2 == 0) {
            b /= 2;
            if (a*a-4*a*b+b*b == 1 and b <= 1e9) {
                p = {a,b};
            }
        }
    }
    cout << 0 << " " << 0 << endl;
    cout << p.first << " " << p.second << endl;
    cout << p.second << " " << p.first << endl;
}