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

long long n;

int main(){

	cin>>n;
	
	cout<<"0 0 1 1000000000 "<<((n+1000000000ll-1ll)/1000000000ll)<<" "<<(((n+1000000000ll-1ll)/1000000000ll)*1000000000ll-n)<<endl;

return 0;
}
