#include <bits/stdc++.h>
using namespace std;
typedef unsigned long long ULL;
int main(){
const int M=1e9;
ULL S, a=M, b=0, c=0, d=M; cin >> S;
if(S<1e18){ b=1; c=M-S%M; d=S/M+1; }  
cout << 0 << " " << 0 << " " << a << " " << b << " " << c << " " << d << "\n";
}