#include<iostream>
using ll = long long;
using namespace std;
int main(){
  ll S;cin>>S;
  ll v=1000000000;
  ll hoge=(v-S%v)%(v);
  ll hoge2=(hoge+S)/(v);
  cout<<0<<" "<<0<<" "<<v<<" "<<1<<" "<<hoge<<" "<<hoge2<<endl;
  //cout<<abs(hoge-hoge2*v)/2<<endl;
  return 0;
}
