#include<bits/stdc++.h>
using namespace std;
#define long long long

int main(){
  long S, X, Y;
  const int c=1e9;
  cin >> S;
  X = (c-S%c)%c;
  Y = (S+X)/c;
  cout << "0 0 1000000000 1 " << X << " " << Y << endl;
  return 0;
}