#include <iostream>
#include <cstdio>
#include <vector>
#include <algorithm>
using namespace std;

vector<int> v;
int main()
{
    int n;
    int n1;
    cin>>n;
    v.assign(n + 1, 0);
    for(int i=0;i<n;i++){
        cin>>v[i];
    }
    sort(v.begin(), v.end());
    if(n%2==0){
        printf("%d\n",v[n/2-1]);
    }
    else{
        printf("%d\n",v[n/2]);
    }

    return 0;
}


#include <iostream>
#include <bits/stdc++.h>
#define LL long long
#define Clear(a,x) memset(a,x,sizeof(a))
using namespace std;
vector<int> V;
int main()
{
    ios::sync_with_stdio(0);cin.tie(0);cout.tie(0);
    int n, x;
    cin >> n;
    for(int i = 0; i < n; i++){
        cin >> x;
        V.push_back(x);
    }
    int flag = 1;
    while(V.size() > 1){
        int len = V.size() - 1;
        if(flag){
            if(V[len] >= V[len - 1]){
                V.pop_back();
            }
        }
        else{
            if(V[len] <= V[len - 1]){
                V.pop_back();
            }
        }
        flag ^= 1;
    }
    cout << V[0] << endl;
    return 0;
}


#include <iostream>

using namespace std;

int main()
{
	int n; // 1-1000
	cin >> n;
	int* a = new int[n];
	for (int i = 0; i < n; i++) {
		cin >> a[i];
	}
	/*for (int i = 1; i < n; i++) {
		int s = a[i];
		int j = i - 1;
		while (j > 0 && a[j] > s) {
			a[j + 1] = a[j];
			j--;
		}
		a[j + 1] = s;
	}
	int last = a[(n + 1) % 2];
	cout << last;*/
	cout << a[0];
}


#include <iostream>

using namespace std;

int main()
{
	int n; // 1-1000
	cin >> n;
	int* a = new int[n];
	for (int i = 0; i < n; i++) {
		cin >> a[i];
	}
	for (int i = 1; i < n; i++) {
		int s = a[i];
		int j = i - 1;
		while (j > 0 && a[j] > s) {
			a[j + 1] = a[j];
			j--;
		}
		a[j + 1] = s;
	}
	int index = floor((n + 1) / 2);
	int last = a[index];
	cout << last;
}


#include <iostream>

using namespace std;

int main()
{
	int n;
	cin >> n;
	int* a = new int[n];
	for (int i = 1; i <= n; i++) {
		cin >> a[i];
	}
	for (int i = 2; i <= n; i++) {
		int s = a[i];
		int j = i - 1;
		while (j > 0 && a[j] > s) {
			a[j + 1] = a[j];
			j--;
		}
		a[j + 1] = s;
	}
	int last = a[(n + 1) / 2];
	cout << last;
}
/*
9
44 53 51 80 5 27 74 79 94

53 a j�
*/


#include <iostream>

using namespace std;

int main()
{
	int n; // 1-1000
	cin >> n;
	int* a = new int[n];
	for (int i = 0; i < n; i++) {
		cin >> a[i];
	}
	for (int i = 1; i < n; i++) {
		int s = a[i];
		int j = i - 1;
		while (j > 0 && a[j] > s) {
			a[j + 1] = a[j];
			j--;
		}
		a[j + 1] = s;
	}
	int index = (n + 1) / 2;
	float last = a[index];
	cout << last;
}


#include <iostream>

using namespace std;

int main()
{
	int n; // 1-1000
	cin >> n;
	int* a = new int[n];
	for (int i = 0; i < n; i++) {
		cin >> a[i];
	}
	for (int i = 1; i < n; i++) {
		int s = a[i];
		int j = i - 1;
		while (j > 0 && a[j] > s) {
			a[j + 1] = a[j];
			j--;
		}
		a[j + 1] = s;
	}
	int last = a[(n + 1) % 2];
	cout << last;
}


#include <iostream>

using namespace std;

int main()
{
	int n; // 1-1000
	cin >> n;
	int* a = new int[n];
	for (int i = 0; i < n; i++) {
		cin >> a[i];
	}
	for (int i = 1; i < n; i++) {
		int s = a[i];
		int j = i - 1;
		while (j > 0 && a[j] > s) {
			a[j + 1] = a[j];
			j--;
		}
		a[j + 1] = s;
	}
	int index = floor((n + 1) / 2);
	float last = a[index];
	cout << last;
}


#include <iostream>
using namespace std;

int main() {
  int n;
  int a[1000];
  do{
    cin >> n;
  }while (n < 1 || n > 1000);
  for (int i = 1; i < n; i++){
    cin >> a[i];
  }
  for (int i = 2; i < n; i++){
    int s = a[i];
    int j = i - 1;
     while(j > 0 && a[j] > s){
       a[j+1]=a[j];
       j=j-1;
     }
    a[j+1] = s ;
  }
  int last = a[(n+1) / 2];
  cout << last;
	return 0;
}


#include <iostream>
using namespace std;

int main() {
  int n;
  int a[1001];
  do{
    cin >> n;
  }while (n < 1 || n > 1001);
  for (int i = 0; i <= n; i++){
    cin >> a[i];
  }
  for (int i = 2; i < n; i++){
    int s = a[i];
    int j = i - 1;
     while(j > 0 && a[j] > s){
       a[j+1]=a[j];
       j=j-1;
     }
    a[j+1] = s;
  }
  int last = a[(n+1) / 2];
  cout << last;
	return 0;
}


#include <iostream>
using namespace std;

int main() {
  int n;
  int a[1000];
  do{
    cin >> n;
  }while (n < 1 || n > 1000);
  for (int i = 1; i <= n; i++){
    cin >> a[i];
  }
  for (int i = 2; i < n; i++){
    int s = a[i];
    int j = i - 1;
     while(j > 0 && a[j] > s){
       a[j+1]=a[j];
       j=j-1;
     }
    a[j+1] = s ;
  }
  int last = a[(n+1) / 2];
  cout << last;
	return 0;
}


#include <iostream>
using namespace std;

int main() {
  int n;
  int a[1000];
  do{
    cin >> n;

  }while (n <= 1 || n >= 1000);

  for (int i = 1; i <= n; i++){
    cin >> a[i];
  }
  for (int i = 2; i < n; i++){
    int s = a[i];
    int j = i - 1;
     while(j > 0 && a[j] > s){
       a[j+1]=a[j];
       j=j-1;
     }
    s= a[j+1];
  }
  int last = a[(n+1) div 2];
  cout << last;
	return 0;
}


#include <iostream>
using namespace std;

int main() {
  int n;
  int a[1000];
  do{
    cin >> n;

  }while (n <= 1 || n >= 1000);

  for (int i = 1; i <= n; i++){
    cin >> a[i];
  }
  for (int i = 2; i < n; i++){
    int s = a[i];
    int j = i - 1;
     while(j > 0 && a[j] > s){
       a[j+1]=a[j];
       j=j-1;
     }
    s= a[j+1];
  }
  for (int i = 1; i >=n; i++){
    cout << (n+1 / 2);

  }
	return 0;
}


#include <iostream>
using namespace std;

int main() {
  int n;
  int a[1000];
  do{
    cin >> n;

  }while (n <= 1 || n >= 1000);

  for (int i = 1; i <= n; i++){
    cin >> a[i];
  }
  for (int i = 2; i < n; i++){
    int s = a[i];
    int j = i - 1;
     while(j > 0 && a[j] > s){
       a[j+1]=a[j];
       j=j-1;
     }
    s= a[j+1];
  }
  int last = a[(n+1) / 2];
  cout << last;
	return 0;
}


#include <iostream>
using namespace std;

int main() {
  int n;
  int a[1001];
  do{
    cin >> n;
  }while (n < 1 || n > 1001);
  for (int i = 1; i <= n; i++){
    cin >> a[i];
  }
  for (int i = 2; i < n; i++){
    int s = a[i];
    int j = i - 1;
     while(j > 0 && a[j] > s){
       a[j+1]=a[j];
       j=j-1;
     }
    a[j+1] = s;
  }
  int last = a[(n+1) / 2];
  cout << last;
	return 0;
}


#include <iostream>
using namespace std;

int main() {
  int n;
  do{
    cin >> n;
  }while (n <= 1 || n > 1001);
  int a[n];
  for (int i = 1; i <= n; i++){
    cin >> a[i];
  }
  for (int i = 2; i < n; i++){
    int s = a[i];
    int j = i - 1;
     while(j > 0 && a[j] > s){
       a[j+1]=a[j];
       j=j-1;
     }
    a[j+1] = s;
  }
  int last = a[(n+1) / 2];
  cout << last;
	return 0;
}


#include <iostream>
using namespace std;

int main() {
  int n;
  int a[1000];
  do{
    cin >> n;
  }while (n <= 1 || n >= 1000);
  for (int i = 1; i <= n; i++){
    cin >> a[i];
  }
  for (int i = 2; i < n; i++){
    int s = a[i];
    int j = i - 1;
     while(j > 0 && a[j] > s){
       a[j+1]=a[j];
       j=j-1;
     }
    a[j+1] = s ;
  }
  int last = a[(n+1) / 2];
  cout << last;
	return 0;
}


#include <iostream>
using namespace std;

int main() {
  int n;
  int a[1001];
  do{
    cin >> n;
  }while (n < 1 || n > 1001);
  for (int i = 1; i <= n; i++){
    cin >> a[i];
  }
  for (int i = 2; i <= n; i++){
    int s = a[i];
    int j = i - 1;
     while(j > 0 && a[j] > s){
       a[j+1]=a[j];
       j=j-1;
     }
    a[j+1] = s;
  }
  int last = a[(n+1) / 2];
  cout << last;
	return 0;
}


#include <iostream>
using namespace std;

int main() {
  int n;
  int a[1001];
  do{
    cin >> n;
  }while (n < 1 || n > 1001);
  for (int i = 1; i < n; i++){
    cin >> a[i];
  }
  for (int i = 2; i < n; i++){
    int s = a[i];
    int j = i - 1;
     while(j > 0 && a[j] > s){
       a[j+1]=a[j];
       j=j-1;
     }
    a[j+1] = s;
  }
  int last = a[(n+1) / 2];
  cout << last;
	return 0;
}


#include <bits/stdc++.h>
#define fast_io ios_base::sync_with_stdio(false);cin.tie(NULL)
#define ll long long int
#define pb push_back
#define mod 1000000007
using namespace std;

int main()
{
   fast_io;
   ll n;
   cin>>n;
   ll a[n];
   ll i;
   for(i=0;i<n;i++)
   {
       cin>>a[i];
   }

   sort(a,a+n);
   cout<<a[n/2];
}


#include <bits/stdc++.h>
#define fast_io ios_base::sync_with_stdio(false);cin.tie(NULL)
#define ll long long int
#define pb push_back
#define mod 1000000007
using namespace std;

int main()
{
   fast_io;
   ll n;
   cin>>n;
   ll a[n];
   ll i;
   for(i=0;i<n;i++)
   {
       cin>>a[i];
   }

   sort(a,a+n);
   if(n%2==0)
   {
       cout<<a[n/2+1];
   }
   else
   {
       cout<<a[n/2]
   }
}


#include <bits/stdc++.h>
#define fast_io ios_base::sync_with_stdio(false);cin.tie(NULL)
#define ll long long int
#define pb push_back
#define mod 1000000007
using namespace std;

int main()
{
   fast_io;
   ll n;
   cin>>n;
   ll a[n];
   ll i;
   for(i=0;i<n;i++)
   {
       cin>>a[i];
   }

   sort(a,a+n);
   if(n%2==0)
   {
       cout<<a[n/2-1];
   }
   else
   {
       cout<<a[n/2];
   }
}


#include <bits/stdc++.h>
#define fast_io ios_base::sync_with_stdio(false);cin.tie(NULL)
#define ll long long int
#define pb push_back
#define mod 1000000007
using namespace std;

int main()
{
   fast_io;
   ll n;
   cin>>n;
   ll a[n];
   ll i;
   for(i=0;i<n;i++)
   {
       cin>>a[i];
   }

   sort(a,a+n);
   if(n%2==0)
   {
       cout<<a[n/2+1];
   }
   else
   {
       cout<<a[n/2];
   }
}


#include <iostream>
#include <algorithm>
using namespace std;

int main()
{
    long int n,a[111],ch;
cin>>n;
for(int i=0;i<n;i++)
    cin>>a[i];
sort(a,a+n);
    cout <<a[(n-1)/2]<< endl;
    return 0;
}


#include <iostream>
#include <algorithm>
using namespace std;

int main()
{
    int n,a[1110];
cin>>n;
for(int i=0;i<n;i++)
{
 cin>>a[i];
}
sort(a,a+n);
    cout <<a[(n-1)/2]<< endl;
    return 0;
}


#include <iostream>

using namespace std;

int main()
{
    long int n,a[111],ch;
cin>>n;

for(int k=0;k<n;k++)
{   cin>>a[k];
    for(int i=0;i<n-1;i++)
{
 if(a[i-1]>a[i]&&i!=0)
{ch=a[i-1];a[i-1]=a[i];a[i]=ch;}
}}
    cout <<a[(n-1)/2]<< endl;
    return 0;
}


#include <iostream>

using namespace std;

int main()
{
    long int n,a[1111],ch;
cin>>n;
for(int i=0;i<n;i++)
{cin>>a[i];}
for(int k=0;k<n;k++)
{for(int i=0;i<n-1;i++)
{
 if(a[i]>a[i+1])
{ch=a[i];a[i]=a[i+1];a[i+1]=ch;}
}}

    cout <<a[(n-1)/2]<< endl;
    return 0;
}


#include <iostream>

using namespace std;

int main()
{
    long int n,a[111],ch;
cin>>n;

for(int k=0;k<n;k++)
{   cin>>a[k];
    for(int i=0;i<n-1;i++)
{
 if(a[i-1]>a[i]&&i!=0)
{ch=a[i-1];a[i-1]=a[i];a[i]=ch;}
}}
    cout <<a[(n)/2]<< endl;
    return 0;
}


#include <iostream>

using namespace std;

int main()
{
    long int n,a[111],ch;
cin>>n;
for(int i=0;i<n;i++)
{cin>>a[i];}
for(int k=0;k<n;k++)
{for(int i=0;i<n-1;i++)
{
 if(a[i]>a[i+1])
{ch=a[i];a[i]=a[i+1];a[i+1]=ch;}
}}

    cout <<a[(n-1)/2]<< endl;
    return 0;
}


#include <iostream>

using namespace std;

int main()
{
    long int n,a[111],ch;
cin>>n;

for(int k=0;k<n;k++)
{   cin>>a[k];
    for(int i=0;i<n-1;i++)
{
 if(a[i]>a[i+1])
{ch=a[i];a[i]=a[i+1];a[i+1]=ch;}
}}

    cout <<a[(n-1)/2]<< endl;
    return 0;
}


#include<math.h>
#include <iostream>
using namespace std;

int main() {

        long n,a[1000];
        cin>>n;
        for(int i=0;i<n;i++)
        {
            cin>>a[i];
        }
        cout<<a[0]<<endl;
        return 0;

}


#include<algorithm>
#include <iostream>
using namespace std;

int main()
{

    int n;
    cin>>n;
    int a[n];

    for(int i=0; i<n; i++)
    {
        cin>>a[i];
    }
    sort(a,a+n);
    cout<<a[(n-1)/2]<<endl;
    return 0;

}


#include<algorithm>
#include <iostream>
using namespace std;

int main() {

        int n;
        int a[n];
        cin>>n;
        for(int i=0;i<n;i++)
        {
            cin>>a[i];
        }
        sort(a,a+n);
        cout<<a[(n-1)/2]<<endl;
        return 0;

}


#include<algorithm>
#include <iostream>
using namespace std;

int main() {

        long n;
        int a[n];
        cin>>n;
        for(int i=0;i<n;i++)
        {
            cin>>a[i];
        }
        sort(a,a+n);
        cout<<a[(n-1)/2]<<endl;
        return 0;

}


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

int main() {

        long n;
        int a[100];
        cin>>n;
        for(int i=0;i<n;i++)
        {
            cin>>a[i];
        }
        sort(a,a+n);
        cout<<a[(n-1)/2]<<endl;
        return 0;

}


#include <iostream>
#include <vector>
#include <algorithm>

using namespace std;

int main(){

    int n;
    cin >> n;
    vector<int> a;
    for (int i = 0; i<n; i++) {
        int x;
        cin >> x;
        a.push_back(x);
    }
    sort(a.begin(),a.end());

    cout << a[((n%2)?n/2:n/2-1)];

    return 0;
}


#include <iostream>
#include <vector>
#include <algorithm>

using namespace std;

int main(){

    int n;
    cin >> n;
    vector<int> a;
    for (int i = 0; i<n; i++) {
        int x;
        cin >> x;
        a.push_back(x);
    }
    sort(a.begin(),a.end());

    if(n%2){
        cout << a[n/2];
    }else
        cout << a[n/2 + 1];

    return 0;
}


#include <iostream>
#include <vector>
#include <algorithm>

using namespace std;

int main(){

    int n;
    cin >> n;
    vector<int> a;
    for (int i = 0; i<n; i++) {
        int x;
        cin >> x;
        a.push_back(x);
    }
    sort(a.begin(),a.end());

    if(n%2){
        cout << a[n/2];
    }else
        cout << a[n/2];

    return 0;
}


#include <iostream>
#include <vector>
#include <algorithm>

using namespace std;

int main(){

    int n;
    vector<int> a;
    cin >> n;
    for (int i = 0;i<n;i++){
        int x;cin>>x;a.push_back(x);
    }
    sort(a.begin(),a.end());
    cout << a[n%2 ? n/2 - 1: n/2];

    return 0;
}


#include <iostream>
#include <vector>
#include <algorithm>

using namespace std;

int main(){

    int n;
    cin >> n;
    vector<int> a;
    for (int i = 0; i<n; i++) {
        int x;
        cin >> x;
        a.push_back(x);
    }
    sort(a.begin(),a.end());

    cout << a[n/2];

    return 0;
}


#include <iostream>
#include <vector>
#include <algorithm>

using namespace std;

int main(){

    int n;
    vector<int> a;
    cin >> n;
    for (int i = 0;i<n;i++){
        int x;cin>>x;a.push_back(x);
    }
    sort(a.begin(),a.end());
    cout << a[n/2];

    return 0;
}


#include <iostream>

using namespace std;

int main() {
    ios_base::sync_with_stdio(false); cin.tie(0);
    int n; cin >> n;
    int ans = -1, a2 = -1;
    for (int i = 0; i < n; i++) {
        int x; cin >> x;
        if (x >= ans) {
            a2 = ans;
            ans = x;
        } else if (x >= a2) {
            a2 = x;
        }
    }
    cout << a2 << endl;
    return 0;
}


#include <iostream>
#include <algorithm>

using namespace std;

int main() {
    ios_base::sync_with_stdio(false); cin.tie(0);
    int n; cin >> n;
    int a[n];
    for (int i = 0; i < n; i++) cin >> a[i];
    sort(a, a + n);
    if (n % 2 == 0) cout << a[n / 2 + 1] << endl;
    else cout << a[n / 2] << endl;
    return 0;
}


#include <stdio.h>
#include <algorithm>

#define sz(x) ((int)(x).size())
#define all(x) (x).begin(), (x).end()
#define X first
#define Y second

using namespace std;

typedef long long ll;
typedef pair<int, int> pii;
typedef long double ld;

const int INF = 1e9;
const long long LINF = 1e18;

const int N = 2000;
int k, s;

int main() {
	scanf("%d", &k);

	s = k + N - 1;

	printf("%d\n", N);
	printf("-1 ");
	printf("%d ", s / 1999 + s % 1999);

	for (int i = 2; i < N; i++) {
		printf("%d ", s / 1999);
	}

	printf("\n");

	return 0;
}


#include <stdio.h>
#include <algorithm>

#define sz(x) ((int)(x).size())
#define all(x) (x).begin(), (x).end()
#define X first
#define Y second

using namespace std;

typedef long long ll;
typedef pair<int, int> pii;
typedef long double ld;

const int INF = 1e9;
const long long LINF = 1e18;

const int N = 2000;
int k, s;

int main() {
	scanf("%d", &k);

	s = k + N - 1;

	printf("-1 ");
	printf("%d ", s - 1998 * (s / 1999));

	for (int i = 2; i < 2000; i++) {
		printf("%d ", s / 1999);
	}

	printf("\n");

	return 0;
}


#include <iostream>
#include <cassert>
using namespace std;

/*
N-a -N N -N N -N N+a

N sum -> tot len
N+a sum -> tot len - 2

N * len << (N + a) * (len - 2) ?
0 >> -2N + a*len - 2a ?
2(N+a) << a*len ??

diff: N * len - (N + a) == k

N = 1000000
len = 2 * something + 1

len <= 1000

-1 -1 -1 -1 -1 N

0 0 0 0 0 0 -a N+a

N + a vs len * N

len*N - N - a == k

N = 1000000

(len - 1)*N == k + a

a < N

len >= 2
*/

int main()
{
    int k;
    cin >> k;

    for (int N = 500000; ; N++) {
        int a = N - k % N; // 1 <= a <= N
        //  0, 0, 0, ..., -a ,a + N
        // alice: a + N (obvious)
        // optimal: a + N or N * len
        if (a + N > 1000000)
            continue;
        int len = (k + a + N) / N;
        if (len < 2 || len > 2000)
            continue;
        assert((k + a + N) % N == 0);

        cout << len << endl;
        for (int i = 0; i < len - 2; i++)
            cout << "0 ";
        cout << -a << " " << a + N << endl;
        break;
    }

    return 0;
}


#include <iostream>
#include <vector>
#include <string>
#include <set>
#include <map>
#include <iomanip>
#include <algorithm>

using namespace std;
#define ll long long
const int MAXN = 1e4;

ll get_closest(ll p)
{
	return (p / 1500) * 1500 + (int)1e6 / 1500 * 1500;
}

int main()
{
	ll k;
	cin >> k;
	ll m = get_closest(k);
	cout << 2000 << '\n';
	for (int i = 0; i < 1497; i++)
	{
		if (i % 2 == 0)
			cout << 1 << ' ';
		else
			cout << -1 << ' ';
	}
	cout << "0 -2 " << (m) / 1500 + 1 << ' ';
	for (int i = 0; i < 499; i++)
	{
		cout << -(1000000) << ' ';
	}
	cout << m - k;
	return 0;
}


#include<stdio.h>
#include<algorithm>
#include<stdlib.h>
#include<iostream>
#include<assert.h>
using namespace std;
int main()
{
	int k;
	scanf("%d", &k);
	cout << 2000 << endl;
	cout << -1 << ' ';
	int sum = k + 1999 + 1;
	for(int i = 2; i <= 2000; i++)
	{
		if(sum >= 1000000)
		{
			cout << 1000000 << ' ';
			sum -= 1000000;
		}
		else
		{
			cout << sum << ' ';
		    sum = 0;
		}
	}
	cout << endl;
	assert(sum == 0);
	//system("pause");
	return  0;
}


#define _USE_MATH_DEFINES
#include <assert.h>
#include <limits.h>
#include <math.h>
#include <memory.h>
#include <algorithm>
#include <bitset>
#include <vector>
#include <string>
#include <list>
#include <set>
#include <map>
#include <unordered_map>
#include <unordered_set>
#include <queue>
#include <sstream>
#include <iostream>
#include <fstream>
#include <iomanip>

using namespace std;
typedef long long     ll;
typedef unsigned int  uint;
#define ALL(a)          (a).begin(), (a).end()
#define FOR(i,a,b)      for(int i = a;   i <  (int)(b); ++i)
#define FOR_REV(i,a,b)  for(int i = b-1; i >= (int)(a); --i)
#define FOR_EACH(it,a)  for(remove_reference<decltype(a)>::type::iterator it = (a).begin(); it != (a).end(); ++it)
#define FOR_EACH_REV(it,a) for(remove_reference<decltype(a)>::type::reverse_iterator it = (a).rbegin(); it != (a).rend(); ++it)
#define FOR_EACH_CONST(it,a) for(remove_reference<decltype(a)>::type::const_iterator it = (a).begin(); it != (a).end(); ++it)
#define FOR_EACH_CONST_REV(it,a) for(remove_reference<decltype(a)>::type::const_reverse_iterator it = (a).rbegin(); it != (a).rend(); ++it)
template<class T> inline T   sqr(T v)  { return v * v; }
template<class T> inline int sign(T v) { return v == 0 ? 0 : (v > 0 ? 1 : -1); }
template<class T> inline int round_i(T t) { return int(t < 0 ? t-0.5f : t+0.5f); } //округлить до ближайшего целого
template<class T> inline int get_bit(T v, int bit_index) { return (v >> bit_index) & 1; } //return {0,1}
template<class T> inline T   gcd(T a, T b) { while(b) { T t = b; b   = a % b; a   = t; } return a; }
#define IN_INT(a)            int a;       is >> a;
#define IN_INT2(a,b)         int a,b;     is >> a >> b;
#define IN_INT3(a,b,c)       int a,b,c;   is >> a >> b >> c;
#define IN_INT4(a,b,c,d)     int a,b,c,d; is >> a >> b >> c >> d;
#define IN_LL(a)             ll a;        is >> a;
#define IN_LL2(a,b)          ll a,b;      is >> a >> b;
#define IN_LL3(a,b,c)        ll a,b,c;    is >> a >> b >> c;
#define IN_LL4(a,b,c,d)      ll a,b,c,d;  is >> a >> b >> c >> d;
#define IN_CHAR(c)           char c;      is >> c;
#define IN_STR(s)            string s;    is >> s;

//////////////////////////////////////////////////////////////////////////
bool io_interactive = true;

istream& input()
{
  ios_base::sync_with_stdio(false);
  if (io_interactive)
    return cin;
#ifdef INPUT_FROM_FILE
  static ifstream is("CodeForces/input.txt");
  return is;
#endif
  if (!io_interactive)
    cin.tie(NULL);
  return cin;
}

ostream& output()
{
  cout << setprecision(15);
  if (!io_interactive)
    cout.tie(NULL);
  return cout;
}

template<class T>
ostream& out_array(ostream& os, const vector<T>& v, bool with_size = true, bool size_on_separate_line = true, bool each_value_on_separate_line = false)
{
  if (with_size)
    os << v.size() << (size_on_separate_line?"\n":" ");
  FOR_EACH_CONST (it, v)
    os << *it << (each_value_on_separate_line?"\n":" ");
  return os;
}

template <typename T>
void init_v2(vector<vector<T>>& v, int lx, int ly, const T& val = T())
{
  v.resize(lx);
  FOR (i,0,lx)
    v[i].resize(ly, val);
};

//////////////////////////////////////////////////////////////////////////
//////////////////////////////////////////////////////////////////////////
////a
//void main()
//{
//  io_interactive = false;
//  istream& is = input();
//  ostream& os = output();
//
//  IN_INT2(n,m);
//  vector<vector<int>> a(n);
//  FOR (i,0,m)
//  {
//    IN_INT2(u,v);
//    a[u-1].push_back(v-1);
//  }
//  FOR (i,0,n)
//    sort(ALL(a[i]));
//
//  FOR (i0,0,n)
//  {
//    int res = 0;
//    FOR (d,0,n)
//    {
//      int i = (i0+d)%n;
//      if (!a[i].empty())
//      {
//        int r = n*(a[i].size()-1) + norm(i-i0,n);
//        int m=INT_MAX;
//        FOR_EACH_CONST(it,a[i])
//          m  = min(m,norm(*it-i,n));
//        res = max(r+m,res);
//      }
//    }
//    os << res<<" ";
//  }
//
//}

//////////////////////////////////////////////////////////////////////////
//b
void main()
{
  io_interactive = false;
  istream& is = input();
  ostream& os = output();

  IN_INT(k);
  //(n1+np)*(s-n1) - s*np = k;
  //-n1^2 + n1()
  int n1 = 1,n=2000;
  int s = k + n;
  os<<n<<"\n-1 ";
  FOR (i,1,n)
  {
    int v;
    if (i==n-1)
      v=s;
    else
      v = s-1e6>=n-i-1?1e6:1;

    s -= v;
    os << v << " ";
  }

  //int res = 0;
  //os << res;
}

//////////////////////////////////////////////////////////////////////////

////c - undone
//void main()
//{
//  io_interactive = false;
//  istream& is = input();
//  ostream& os = output();
//
//  IN_INT(n);
//  string s;
//  const char* w[4] = {"0011", "0101", "1110", "1111"};
//  ll res = 0;
//  FOR (i,0,n)
//  {
//    IN_CHAR(c);
//
//    os << res<< "\n";
//  }
//
//}

//////////////////////////////////////////////////////////////////////////

//void main()
//{
//  io_interactive = false;
//  istream& is = input();
//  ostream& os = output();
//
//  IN_INT(n);
//
//  //vector<int> a(n);
//  //FOR (i,0,n)
//  //  is >> a[i];
//
//  //int res = 0;
//  //os << res;
//}


k = int(input())
# (s+x)(l+1) - sx = k, s + lx + x = k
a = []
for l in range(1, 2001):
    if 0 <= k + (l+1) < l * 10**6:
        s = k + (l+1)
        a.append(-1)
        a.append(s % 10**6)
        s = s - s % 10**6
        for i in range(1, l):
            a.append(10**6)
        break
print(len(a))
for x in a:
    print(x, end=' ')


k = int(input())
# s + lx + x = k
a = []
for l in range(1, 2001):
    if 0 <= k + (l+1) <= l * 10**6:
        s = k + (l+1)
        a.append(-1)
        a.append(s % 10**6)
        s = s - s % 10**6
        for i in range(1, l):
            a.append(10**6)
        break
for x in a:
    print(x, end=' ')


from __future__ import print_function
def printf(s, *args):
    print(s % args, end="")

k = int(input())
N = 2000 - k % 2
printf("%i\n", N)
printf("%i %i ", 0, -1)

remain = (k + N) / 2
for i in range(N - 2):
    v = min(1e6, remain)
    remain -= v
    printf("%i ", v)
printf("\n")


k = int(input())+2
base = 999999
A = [-1] + [base+1]*(k//base) + [k%base]
print(len(A))
print(*A)


import math
k=int(input())
init=[0]*1997+[-1,1]
init[-1]+=math.ceil((k+999)/1998)
curr=(init[-1]-1)*1999-init[-1]
init[-2]-=curr-k
init[-1]+=curr-k
print(1999)
init=[str(guy) for guy in init]
print(" ".join(init))


import math
k=int(input())
init=[0,-1]*999+[999]
init[-1]+=math.ceil((k+999)/1998)
curr=(init[-1]-999)*1999-init[-1]
init[-2]-=curr-k
init[-1]+=curr-k
print(1999)
init=[str(guy) for guy in init]
print(" ".join(init))


import random

INF = 999999999999999999L
EPS = 1e-12

def read():
    return raw_input().strip()

def read_ints():
    return map(int,read().split())

def build(x,y,n):
    ret = [0]*n
    ret[-1] = x
    ret[0] = -y
    return ret

def check(ans, k):
    n = len(ans)
    assert sum(ans) > 0
    best = sum(ans) * n
    output = ans[-1]
    assert best - output == k

def solve(n, k):
    # print "solve",n
    xmodn = (n - k%n) %n
    z = (xmodn - 996000%n) %n
    x = 996000 + z
    assert x%n == xmodn
    assert (k+x)%n == 0

    y = x - (k+x)/n
    if 0 <= y < x:
        return build(x, y, n)
    else:
        return None

k = int(read())

# for _ in range(100):
    # k = random.randint(1,1000000000)
    # print k
for n in range(2,2001):
    ans = solve(n,k)
    if ans is not None:
        check(ans,k)
        print n
        print " ".join(map(str,ans))
        break


'''
Wrong Answer
2019 02 24
Codeforces round #542 division 1 problem B
 - constructive algorithm, ad hoc
'''
import random

INF = 999999999999999999L
EPS = 1e-12

def read():
    return raw_input().strip()

def read_ints():
    return map(int,read().split())

def build(x,y,n):
    target_sum = x-y
    ret = [0]*n

    if n%2 == 1:
        for i in range(n-1):
            ret[i] = 1 if i%2 == 0 else -2
    else:
        for i in range(n-1):
            ret[i] = 1 if i%2 == 1 else -2

    y += sum(ret)
    ret[0] -= y
    ret[-1] = x
    assert sum(ret) == target_sum
    return ret

def check(ans, k):
    n = len(ans)
    assert max(ans) <= 10**6
    assert min(ans) >= -10**6
    assert sum(ans) > 0
    best = sum(ans) * n

    res = 0
    cur = 0
    j = -1
    for i in range(n):
        cur = cur + ans[i]
        if cur < 0:
            cur = 0
            j = i
        res = max(res, (i-j)*cur)
    # print best,res
    assert best - res == k

def solve(n, k):
    xmodn = (n - k%n) %n
    z = (xmodn - 996000%n) %n
    x = 996000 + z
    assert x%n == xmodn
    assert (k+x)%n == 0

    y = x - (k+x)/n
    if 0 <= y < x:
        # print n,y,x
        assert n*(x-y) - x == k
        return build(x, y, n)
    else:
        return None

k = int(read())
# for _ in range(10000):
    # k = random.randint(1,1000000000)
    # print k
for n in range(2,2001):
    ans = solve(n,k)
    if ans is not None:
        print n
        print " ".join(map(str,ans))
        check(ans,k)
        break
else:
    assert False


import random

INF = 999999999999999999L
EPS = 1e-12

def read():
    return raw_input().strip()

def read_ints():
    return map(int,read().split())

def build(x,y,n):
    target_sum = x-y
    ret = [0]*n

    if n%2 == 1:
        for i in range(n-1):
            ret[i] = 1 if i%2 == 0 else -2
    else:
        for i in range(n-1):
            ret[i] = 1 if i%2 == 1 else -2

    y += sum(ret)
    ret[0] -= y
    ret[-1] = x
    assert sum(ret) == target_sum
    return ret

def check(ans, k):
    n = len(ans)
    assert max(ans) <= 10**6
    assert min(ans) >= -10**6
    assert sum(ans) > 0
    best = sum(ans) * n

    res = 0
    cur = 0
    j = -1
    for i in range(n):
        cur = cur + ans[i]
        if cur < 0:
            cur = 0
            j = i
        res = max(res, (i-j)*cur)
    # print best,res
    assert best - res == k

def solve(n, k):
    xmodn = (n - k%n) %n
    z = (xmodn - 996000%n) %n
    x = 996000 + z
    assert x%n == xmodn
    assert (k+x)%n == 0

    y = x - (k+x)/n
    if 0 < y < x:
        # print n,y,x
        assert n*(x-y) - x == k
        return build(x, y, n)
    else:
        return None

k = int(read())
# for _ in range(10000):
    # k = random.randint(1,1000000000)
    # print k
for n in range(2,2001):
    ans = solve(n,k)
    if ans is not None:
        print n
        print " ".join(map(str,ans))
        check(ans,k)
        break
else:
    assert False


using System;
using System.Collections.Generic;
using System.Linq;
using System.Linq.Expressions;
using System.IO;
using System.Text;
using System.Diagnostics;

using static util;
using P = pair<int, int>;

using Binary = System.Func<System.Linq.Expressions.ParameterExpression,
                           System.Linq.Expressions.ParameterExpression,
                           System.Linq.Expressions.BinaryExpression>;
using Unary = System.Func<System.Linq.Expressions.ParameterExpression,
                          System.Linq.Expressions.UnaryExpression>;

class Program {
    static StreamWriter sw = new StreamWriter(Console.OpenStandardOutput()) { AutoFlush = false };
    static Scan sc = new Scan();
    const int M = 1000000007;
    const int M2 = 998244353;
    const long LM = 1L << 60;
    const double eps = 1e-11;
    static readonly int[] dd = { 0, 1, 0, -1, 0 };
    const string dstring = "RDLU";
    static void Main(string[] args)
    {
        long k = sc.Long;
        int n = 1500;
        long a = -1;
        long c = -1;
        for (long i = 1; i < 200000; i++)
        {
            if ((i * n + k) % (n - 1) == 0) {
                a = i;
                c = (i * n + k) / (n - 1);
                break;
            }
        }
        Prt(n);
        var ans = new long[n];
        ans[n - 2] = -a;
        ans[n - 1] = c;
        Prt(ans);
        sw.Flush();
    }

    static void DBG(string a) => Console.WriteLine(a);
    static void DBG<T>(IEnumerable<T> a) => DBG(string.Join(" ", a));
    static void DBG(params object[] a) => DBG(string.Join(" ", a));
    static void Prt(string a) => sw.WriteLine(a);
    static void Prt<T>(IEnumerable<T> a) => Prt(string.Join(" ", a));
    static void Prt(params object[] a) => Prt(string.Join(" ", a));
}
class pair<T, U> : IComparable<pair<T, U>> {
    public T v1;
    public U v2;
    public pair() : this(default(T), default(U)) {}
    public pair(T v1, U v2) { this.v1 = v1; this.v2 = v2; }
    public int CompareTo(pair<T, U> a) {
        int c = Comparer<T>.Default.Compare(v1, a.v1);
        return c != 0 ? c : Comparer<U>.Default.Compare(v2, a.v2);
    }
    public override string ToString() => v1 + " " + v2;
    public void Deconstruct(out T a, out U b) { a = v1; b = v2; }
    public static bool operator>(pair<T, U> a, pair<T, U> b) => a.CompareTo(b) > 0;
    public static bool operator<(pair<T, U> a, pair<T, U> b) => a.CompareTo(b) < 0;
    public static bool operator>=(pair<T, U> a, pair<T, U> b) => a.CompareTo(b) >= 0;
    public static bool operator<=(pair<T, U> a, pair<T, U> b) => a.CompareTo(b) <= 0;
}
static class util {
    public static pair<T, U> make_pair<T, U>(T v1, U v2) => new pair<T, U>(v1, v2);
    public static T sq<T>(T a) => Operator<T>.Multiply(a, a);
    public static T Max<T>(params T[] a) => a.Max();
    public static T Min<T>(params T[] a) => a.Min();
    public static bool inside(int i, int j, int h, int w) => i >= 0 && i < h && j >= 0 && j < w;
    public static Dictionary<T, int> compress<T>(this IEnumerable<T> a)
        => a.Distinct().OrderBy(v => v).Select((v, i) => new { v, i }).ToDictionary(p => p.v, p => p.i);
    public static Dictionary<T, int> compress<T>(params IEnumerable<T>[] a) => compress(a.Aggregate(Enumerable.Union));
    public static void swap<T>(ref T a, ref T b) where T : struct { var t = a; a = b; b = t; }
    public static void swap<T>(this IList<T> a, int i, int j) where T : struct { var t = a[i]; a[i] = a[j]; a[j] = t; }
    public static T[] copy<T>(this IList<T> a) {
        var ret = new T[a.Count];
        for (int i = 0; i < a.Count; i++) ret[i] = a[i];
        return ret;
    }
}
static class Operator<T> {
    static readonly ParameterExpression x = Expression.Parameter(typeof(T), "x");
    static readonly ParameterExpression y = Expression.Parameter(typeof(T), "y");
    public static readonly Func<T, T, T> Add = Lambda(Expression.Add);
    public static readonly Func<T, T, T> Subtract = Lambda(Expression.Subtract);
    public static readonly Func<T, T, T> Multiply = Lambda(Expression.Multiply);
    public static readonly Func<T, T, T> Divide = Lambda(Expression.Divide);
    public static readonly Func<T, T> Plus = Lambda(Expression.UnaryPlus);
    public static readonly Func<T, T> Negate = Lambda(Expression.Negate);
    public static Func<T, T, T> Lambda(Binary op) => Expression.Lambda<Func<T, T, T>>(op(x, y), x, y).Compile();
    public static Func<T, T> Lambda(Unary op) => Expression.Lambda<Func<T, T>>(op(x), x).Compile();
}

class Scan {
    StreamReader sr;
    public Scan() { sr = new StreamReader(Console.OpenStandardInput()); }
    public Scan(string path) { sr = new StreamReader(path); }
    public int Int => int.Parse(Str);
    public long Long => long.Parse(Str);
    public double Double => double.Parse(Str);
    public string Str => sr.ReadLine().Trim();
    public pair<T, U> Pair<T, U>() {
        T a; U b;
        Multi(out a, out b);
        return new pair<T, U>(a, b);
    }
    public P P => Pair<int, int>();
    public int[] IntArr => StrArr.Select(int.Parse).ToArray();
    public long[] LongArr => StrArr.Select(long.Parse).ToArray();
    public double[] DoubleArr => StrArr.Select(double.Parse).ToArray();
    public string[] StrArr => Str.Split(new[]{' '}, StringSplitOptions.RemoveEmptyEntries);
    bool eq<T, U>() => typeof(T).Equals(typeof(U));
    T ct<T, U>(U a) => (T)Convert.ChangeType(a, typeof(T));
    T cv<T>(string s) => eq<T, int>()    ? ct<T, int>(int.Parse(s))
                       : eq<T, long>()   ? ct<T, long>(long.Parse(s))
                       : eq<T, double>() ? ct<T, double>(double.Parse(s))
                       : eq<T, char>()   ? ct<T, char>(s[0])
                                         : ct<T, string>(s);
    public void Multi<T>(out T a) => a = cv<T>(Str);
    public void Multi<T, U>(out T a, out U b)
    { var ar = StrArr; a = cv<T>(ar[0]); b = cv<U>(ar[1]); }
    public void Multi<T, U, V>(out T a, out U b, out V c)
    { var ar = StrArr; a = cv<T>(ar[0]); b = cv<U>(ar[1]); c = cv<V>(ar[2]); }
    public void Multi<T, U, V, W>(out T a, out U b, out V c, out W d)
    { var ar = StrArr; a = cv<T>(ar[0]); b = cv<U>(ar[1]); c = cv<V>(ar[2]); d = cv<W>(ar[3]); }
    public void Multi<T, U, V, W, X>(out T a, out U b, out V c, out W d, out X e)
    { var ar = StrArr; a = cv<T>(ar[0]); b = cv<U>(ar[1]); c = cv<V>(ar[2]); d = cv<W>(ar[3]); e = cv<X>(ar[4]); }
}


package main

import (
	"bytes"
	"fmt"
	"io/ioutil"
	"os"
)

func main() {
	bs, _ := ioutil.ReadAll(os.Stdin)
	reader := bytes.NewBuffer(bs)
	var k int
	fmt.Fscanf(reader, "%d", &k)
	n, s := 2000, 2000 + k
	fmt.Printf("-1")
	for i := 1;i < n;i ++ {
		if s >= 1000000 {
			fmt.Printf(" 1000000")
			s -= 1000000
		} else {
			fmt.Printf(" %d", s)
			s = 0
		}
	}
}


package main

import (
	"bytes"
	"fmt"
	"io/ioutil"
	"os"
)

func main() {
	bs, _ := ioutil.ReadAll(os.Stdin)
	reader := bytes.NewBuffer(bs)
	var k int
	fmt.Fscanf(reader, "%d", &k)
	n, s := 2000, 2000 + k
	fmt.Printf("2000\n-1")
	for i := 1;i < n;i ++ {
		if s >= 1000000 {
			fmt.Printf(" 1000000")
			s -= 1000000
		} else {
			fmt.Printf(" %d", s)
			s = 0
		}
	}
}


package main

import (
	. "fmt"
	"io"
	"os"
)

// github.com/EndlessCheng/codeforces-go
func CF1129B(in io.Reader, out io.Writer) {
	min := func(a, b int) int {
		if a < b {
			return a
		}
		return b
	}
	Fprint(out, "2000\n-1")
	var k int
	Fscan(in, &k)
	k += 2000
	for i := 1; i < 2000; i++ {
		v := min(1e6, k)
		Fprint(out, " ", v)
		k -= v
	}
}

func main() { CF1129B(os.Stdin, os.Stdout) }


# S - n + 1 = k
# S = k + n - 1
# [-1, 1, k + n - 1]
# [-1, 1, 10**6, ..., (k + n - 1)]

k = int(raw_input())

def answer(k, n):
    n2 = n - 2 - 1
    k2 = k - n2 * 10 ** 6

    if (k2 + n - 1) > 10 ** 6:
        return None

    a = ['-1', '1']
    for _ in xrange(n2):
        a.append('1000000')
    a.append(str(k2 + n - 1))
    return a

found = False
for i in xrange(3, 2001):
    ans = answer(k, i)
    if ans is not None:
        print i
        print ' '.join(ans)
        found = True
        break

if not found:
    print -1


k = int(input())
n = 2000
S = n + k
ans = [0] * n
ans[0] = -1
residue = (S) % (n - 1)
for i in range(1, n):
    ans[i] = (S) // (n - 1)
    if residue > 0:
        ans[i] += 1
        residue -= 1
print(2000)
print(' '.join(map(str, ans)))


k = int(input())
n = 2000
S = n + k
ans = [0] * n
ans[0] = -1
residue = (S + 1) % (n - 1)
for i in range(1, n):
    ans[i] = (S + 1) // (n - 1)
    if residue > 0:
        ans[i] += 1
        residue -= 1
print(2000)
print(' '.join(map(str, ans)))


k = int(input())
n = 2000
S = n + k
ans = [0] * n
ans[0] = -1
residue = (S + 1) % (n - 1)
for i in range(1, n):
    ans[i] = (S + 1) // (n - 1)
    if residue > 0:
        ans[i] += 1
        residue -= 1
print(' '.join(map(str, ans)))


def solve(Z):
    if Z <= 1:
        return [-1, X+2]

    l = min(1999, Z)
    m = l + 1

    Y = (Z+1)//(m-1) + 1
    c = Y*(m-1) - (Z+1)
    X = Y + c + 1

    ans = [X, -(X+1)]

    for _ in range(m-3):
        ans.append(0)

    ans.append(Y+1)

    return ans

Z = int(input())
ans = solve(Z)
print(len(ans))
print(' '.join([str(x) for x in ans]))


def solve(Z):
    if Z <= 1000000-10:
        return [-1, Z+2]

    for l in range(2000):
        m = l + 1

        if m < 4 or m > 2000:
            continue

        Y = (Z+1)//(m-1) + 1
        c = Y*(m-1) - (Z+1)
        X = Y + c + 1

        if X >= 1000000 or Y+2>=1000000:
            continue

        if Y >= m/2-1:
            ans = [X, -(X+1)]

            for _ in range(m-4):
                ans.append(0)

            ans.append(-1)
            ans.append(Y+2)

        return ans
    return -1

Z = int(input())
ans = solve(Z)
print(len(ans))
print(' '.join([str(x) for x in ans]))


def solve(Z):
    if Z <= 1000000-10:
        return [-1, Z+2]

    l = 1999
    m = l + 1

    Y = (Z+1)//(m-1) + 1
    c = Y*(m-1) - (Z+1)
    X = Y + c + 1

    ans = [X, -(X+1)]

    for _ in range(m-4):
        ans.append(0)

    ans.append(-1)
    ans.append(Y+2)

    return ans

Z = int(input())
ans = solve(Z)
print(len(ans))
print(' '.join([str(x) for x in ans]))


def solve(Z):
    if Z <= 1000000-10:
        return [-1, Z+2]

    for l in range(2000):
        m = l + 1

        if m < 4 or m > 2000:
            continue

        Y = (Z+1)//(m-1) + 1
        c = Y*(m-1) - (Z+1)
        X = Y + c + 1

        if Y >= m/2-1:
            ans = [X, -(X+1)]

            for _ in range(m-4):
                ans.append(0)

            ans.append(-1)
            ans.append(Y+2)

        return ans
    return -1

Z = int(input())
ans = solve(Z)
print(len(ans))
print(' '.join([str(x) for x in ans]))


n = int(input())
ans = [-1]
n = n + 2
while n > 0:
    add = min(n,1000000)
    ans.append(add)
    n -= add
print(len(ans))
for i in ans:
    print(i,end=" ")
print()


n = int(input())
ans = [-1]
n += 1
while n > 0:
    n += 1
    add = min(n,1000000)
    ans.append(add)
    n -= add
print(len(ans))
for i in ans:
    print(i,end=" ")
print()


#!/usr/bin/env python
from __future__ import division, print_function

import os
import sys
from io import BytesIO, IOBase

if sys.version_info[0] < 3:
    from __builtin__ import xrange as range
    from future_builtins import ascii, filter, hex, map, oct, zip

def main():
    k = int(input())

    m = -k % 2000
    while ((k + m) // 2000) + 1 > m:
        m += 2000

    print(2000)
    print(m, -m, *([0] * 1996), -1, ((k + m) // 2000) + 1)

# region fastio

BUFSIZE = 8192

class FastIO(IOBase):
    newlines = 0

    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()

    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)

class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")

def print(*args, **kwargs):
    """Prints the values to a stream, or to sys.stdout by default."""
    sep, file = kwargs.pop("sep", " "), kwargs.pop("file", sys.stdout)
    at_start = True
    for x in args:
        if not at_start:
            file.write(sep)
        file.write(str(x))
        at_start = False
    file.write(kwargs.pop("end", "\n"))
    if kwargs.pop("flush", False):
        file.flush()

if sys.version_info[0] < 3:
    sys.stdin, sys.stdout = FastIO(sys.stdin), FastIO(sys.stdout)
else:
    sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)

input = lambda: sys.stdin.readline().rstrip("\r\n")

# endregion

if __name__ == "__main__":
    main()


#!/usr/bin/env python
from __future__ import division, print_function

import os
import sys
from io import BytesIO, IOBase

if sys.version_info[0] < 3:
    from __builtin__ import xrange as range
    from future_builtins import ascii, filter, hex, map, oct, zip

def main():
    k = int(input())

    found = False
    for i in range(2, max(4, min(2001, int(k ** 0.5) + 1))):
        if i == 2 and k % 2 == 0 and 3 <= k // 2 <= 2000:
            i = k // 2
        elif i == 2:
            continue

        if k % i == 0:
            found = True
            a = (2 * k) // i + 1 + (i - 3)
            print(i)
            print(k, -k - 1, *[-1] * (i - 3), a)
            break

    if not found:
        print(-1)

# region fastio

BUFSIZE = 8192

class FastIO(IOBase):
    newlines = 0

    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()

    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)

class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")

def print(*args, **kwargs):
    """Prints the values to a stream, or to sys.stdout by default."""
    sep, file = kwargs.pop("sep", " "), kwargs.pop("file", sys.stdout)
    at_start = True
    for x in args:
        if not at_start:
            file.write(sep)
        file.write(str(x))
        at_start = False
    file.write(kwargs.pop("end", "\n"))
    if kwargs.pop("flush", False):
        file.flush()

if sys.version_info[0] < 3:
    sys.stdin, sys.stdout = FastIO(sys.stdin), FastIO(sys.stdout)
else:
    sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)

input = lambda: sys.stdin.readline().rstrip("\r\n")

# endregion

if __name__ == "__main__":
    main()


#!/usr/bin/env python
from __future__ import division, print_function

import os
import sys
from io import BytesIO, IOBase

if sys.version_info[0] < 3:
    from __builtin__ import xrange as range
    from future_builtins import ascii, filter, hex, map, oct, zip

def main():
    k = int(input())

    found = False
    for i in range(2, min(2001, k)):
        if i == 2 and k % 2 == 0 and 3 <= k // 2 <= 2000:
            i = k // 2
        elif i == 2:
            continue

        if k % i == 0:
            found = True

            padding = [0] * (i - 3)
            if padding:
                padding[-1] = -1

            a = (2 * k) // i + 1

            print(i)
            print(k, -k - (1 if not padding else 0), *padding, a)
            break

    if not found:
        print(-1)

# region fastio

BUFSIZE = 8192

class FastIO(IOBase):
    newlines = 0

    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()

    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)

class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")

def print(*args, **kwargs):
    """Prints the values to a stream, or to sys.stdout by default."""
    sep, file = kwargs.pop("sep", " "), kwargs.pop("file", sys.stdout)
    at_start = True
    for x in args:
        if not at_start:
            file.write(sep)
        file.write(str(x))
        at_start = False
    file.write(kwargs.pop("end", "\n"))
    if kwargs.pop("flush", False):
        file.flush()

if sys.version_info[0] < 3:
    sys.stdin, sys.stdout = FastIO(sys.stdin), FastIO(sys.stdout)
else:
    sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)

input = lambda: sys.stdin.readline().rstrip("\r\n")

# endregion

if __name__ == "__main__":
    main()


#!/usr/bin/env python
from __future__ import division, print_function

import os
import sys
from io import BytesIO, IOBase

if sys.version_info[0] < 3:
    from __builtin__ import xrange as range
    from future_builtins import ascii, filter, hex, map, oct, zip

def main():
    k = int(input())

    m = -k % 2000
    while ((k + m) // 2000) + 1 > m:
        m = ((k + m) // 2000) + 1
        m += -m % 2000

    print(2000)
    print(m, -m, *([0] * 1996), -1, ((k + m) // 2000) + 1)

# region fastio

BUFSIZE = 8192

class FastIO(IOBase):
    newlines = 0

    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()

    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)

class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")

def print(*args, **kwargs):
    """Prints the values to a stream, or to sys.stdout by default."""
    sep, file = kwargs.pop("sep", " "), kwargs.pop("file", sys.stdout)
    at_start = True
    for x in args:
        if not at_start:
            file.write(sep)
        file.write(str(x))
        at_start = False
    file.write(kwargs.pop("end", "\n"))
    if kwargs.pop("flush", False):
        file.flush()

if sys.version_info[0] < 3:
    sys.stdin, sys.stdout = FastIO(sys.stdin), FastIO(sys.stdout)
else:
    sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)

input = lambda: sys.stdin.readline().rstrip("\r\n")

# endregion

if __name__ == "__main__":
    main()


import sys
try:
	sys.stdin = open('in.in','r')
	sys.stdout = open('out.out','w')
except: pass

k = int(input())

print(2000)
k += 2000
print(-1,end=' ')
for i in range(1999):
	if not k: print(0,end=' ')
	else:
		if k <= 1000000:
			print(k,end=' ')
			k = 0
		else:
			print(1000000,end=' ')
			k -= 1000000


import sys
#sys.stdin=open("data.txt")
input=sys.stdin.readline
mii=lambda:map(int,input().split())

def bad(a):
    res=0
    cur=0
    k=-1
    for i in range(len(a)):
        cur+=a[i]
        if cur<0:
            cur=0
            k=i
        res=max(res,(i-k)*cur)
    return res

def what(a):
    ans=0
    ps=[0]
    for i in a:
        ps.append(ps[-1]+i)
    for i in range(len(a)):
        for j in range(i+1,len(a)+1):
            ans=max(ans,(j-i)*(ps[j]-ps[i]))
    return ans-bad(a)

k=int(input())
a=[1,-1]+[0]*1996

# get last two numbers
thing=1999-k%1999
if thing==0: thing=1999
a.append(-thing)
a.append(thing+1+k//1999)
print(2000)
print(" ".join(map(str,a)))


import sys
#sys.stdin=open("data.txt")
input=sys.stdin.readline
mii=lambda:map(int,input().split())

def bad(a):
    res=0
    cur=0
    k=-1
    for i in range(len(a)):
        cur+=a[i]
        if cur<0:
            cur=0
            k=i
        res=max(res,(i-k)*cur)
    return res

def what(a):
    ans=0
    ps=[0]
    for i in a:
        ps.append(ps[-1]+i)
    for i in range(len(a)):
        for j in range(i+1,len(a)+1):
            ans=max(ans,(j-i)*(ps[j]-ps[i]))
    return ans-bad(a)

k=int(input())
a=[1,-1]+[0]*1996

# get last two numbers
thing=1999-k%1999
if thing==0: thing=1999
a.append(-thing)
a.append(thing+1+k//1999)
print(" ".join(map(str,a)))


# ---------------------------iye ha aam zindegi---------------------------------------------
import math
import random
import heapq, bisect
import sys
from collections import deque, defaultdict
from fractions import Fraction
import sys
import threading
from collections import defaultdict
#threading.stack_size(10**8)
mod = 10 ** 9 + 7
mod1 = 998244353

# ------------------------------warmup----------------------------
import os
import sys
from io import BytesIO, IOBase
#sys.setrecursionlimit(300000)

BUFSIZE = 8192

class FastIO(IOBase):
    newlines = 0

    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()

    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)

class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")

sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)
input = lambda: sys.stdin.readline().rstrip("\r\n")

# -------------------game starts now----------------------------------------------------import math
class TreeNode:
    def __init__(self, k, v):
        self.key = k
        self.value = v
        self.left = None
        self.right = None
        self.parent = None
        self.height = 1
        self.num_left = 1
        self.num_total = 1

class AvlTree:

    def __init__(self):
        self._tree = None

    def add(self, k, v):
        if not self._tree:
            self._tree = TreeNode(k, v)
            return
        node = self._add(k, v)
        if node:
            self._rebalance(node)

    def _add(self, k, v):
        node = self._tree
        while node:
            if k < node.key:
                if node.left:
                    node = node.left
                else:
                    node.left = TreeNode(k, v)
                    node.left.parent = node
                    return node.left
            elif node.key < k:
                if node.right:
                    node = node.right
                else:
                    node.right = TreeNode(k, v)
                    node.right.parent = node
                    return node.right
            else:
                node.value = v
                return

    @staticmethod
    def get_height(x):
        return x.height if x else 0

    @staticmethod
    def get_num_total(x):
        return x.num_total if x else 0

    def _rebalance(self, node):

        n = node
        while n:
            lh = self.get_height(n.left)
            rh = self.get_height(n.right)
            n.height = max(lh, rh) + 1
            balance_factor = lh - rh
            n.num_total = 1 + self.get_num_total(n.left) + self.get_num_total(n.right)
            n.num_left = 1 + self.get_num_total(n.left)

            if balance_factor > 1:
                if self.get_height(n.left.left) < self.get_height(n.left.right):
                    self._rotate_left(n.left)
                self._rotate_right(n)
            elif balance_factor < -1:
                if self.get_height(n.right.right) < self.get_height(n.right.left):
                    self._rotate_right(n.right)
                self._rotate_left(n)
            else:
                n = n.parent

    def _remove_one(self, node):
        """
        Side effect!!! Changes node. Node should have exactly one child
        """
        replacement = node.left or node.right
        if node.parent:
            if AvlTree._is_left(node):
                node.parent.left = replacement
            else:
                node.parent.right = replacement
            replacement.parent = node.parent
            node.parent = None
        else:
            self._tree = replacement
            replacement.parent = None
        node.left = None
        node.right = None
        node.parent = None
        self._rebalance(replacement)

    def _remove_leaf(self, node):
        if node.parent:
            if AvlTree._is_left(node):
                node.parent.left = None
            else:
                node.parent.right = None
            self._rebalance(node.parent)
        else:
            self._tree = None
        node.parent = None
        node.left = None
        node.right = None

    def remove(self, k):
        node = self._get_node(k)
        if not node:
            return
        if AvlTree._is_leaf(node):
            self._remove_leaf(node)
            return
        if node.left and node.right:
            nxt = AvlTree._get_next(node)
            node.key = nxt.key
            node.value = nxt.value
            if self._is_leaf(nxt):
                self._remove_leaf(nxt)
            else:
                self._remove_one(nxt)
            self._rebalance(node)
        else:
            self._remove_one(node)

    def get(self, k):
        node = self._get_node(k)
        return node.value if node else -1

    def _get_node(self, k):
        if not self._tree:
            return None
        node = self._tree
        while node:
            if k < node.key:
                node = node.left
            elif node.key < k:
                node = node.right
            else:
                return node
        return None

    def get_at(self, pos):
        x = pos + 1
        node = self._tree
        while node:
            if x < node.num_left:
                node = node.left
            elif node.num_left < x:
                x -= node.num_left
                node = node.right
            else:
                return (node.key, node.value)
        raise IndexError("Out of ranges")

    @staticmethod
    def _is_left(node):
        return node.parent.left and node.parent.left == node

    @staticmethod
    def _is_leaf(node):
        return node.left is None and node.right is None

    def _rotate_right(self, node):
        if not node.parent:
            self._tree = node.left
            node.left.parent = None
        elif AvlTree._is_left(node):
            node.parent.left = node.left
            node.left.parent = node.parent
        else:
            node.parent.right = node.left
            node.left.parent = node.parent
        bk = node.left.right
        node.left.right = node
        node.parent = node.left
        node.left = bk
        if bk:
            bk.parent = node
        node.height = max(self.get_height(node.left), self.get_height(node.right)) + 1
        node.num_total = 1 + self.get_num_total(node.left) + self.get_num_total(node.right)
        node.num_left = 1 + self.get_num_total(node.left)

    def _rotate_left(self, node):
        if not node.parent:
            self._tree = node.right
            node.right.parent = None
        elif AvlTree._is_left(node):
            node.parent.left = node.right
            node.right.parent = node.parent
        else:
            node.parent.right = node.right
            node.right.parent = node.parent
        bk = node.right.left
        node.right.left = node
        node.parent = node.right
        node.right = bk
        if bk:
            bk.parent = node
        node.height = max(self.get_height(node.left), self.get_height(node.right)) + 1
        node.num_total = 1 + self.get_num_total(node.left) + self.get_num_total(node.right)
        node.num_left = 1 + self.get_num_total(node.left)

    @staticmethod
    def _get_next(node):
        if not node.right:
            return node.parent
        n = node.right
        while n.left:
            n = n.left
        return n

# -----------------------------------------------binary seacrh tree---------------------------------------
class SegmentTree1:
    def __init__(self, data, default=300006, func=lambda a, b: min(a , b)):
        """initialize the segment tree with data"""
        self._default = default
        self._func = func
        self._len = len(data)
        self._size = _size = 1 << (self._len - 1).bit_length()

        self.data = [default] * (2 * _size)
        self.data[_size:_size + self._len] = data
        for i in reversed(range(_size)):
            self.data[i] = func(self.data[i + i], self.data[i + i + 1])

    def __delitem__(self, idx):
        self[idx] = self._default

    def __getitem__(self, idx):
        return self.data[idx + self._size]

    def __setitem__(self, idx, value):
        idx += self._size
        self.data[idx] = value
        idx >>= 1
        while idx:
            self.data[idx] = self._func(self.data[2 * idx], self.data[2 * idx + 1])
            idx >>= 1

    def __len__(self):
        return self._len

    def query(self, start, stop):
        if start == stop:
            return self.__getitem__(start)
        stop += 1
        start += self._size
        stop += self._size

        res = self._default
        while start < stop:
            if start & 1:
                res = self._func(res, self.data[start])
                start += 1
            if stop & 1:
                stop -= 1
                res = self._func(res, self.data[stop])
            start >>= 1
            stop >>= 1
        return res

    def __repr__(self):
        return "SegmentTree({0})".format(self.data)

# -------------------game starts now----------------------------------------------------import math
class SegmentTree:
    def __init__(self, data, default=0, func=lambda a, b:max(a , b)):
        """initialize the segment tree with data"""
        self._default = default
        self._func = func
        self._len = len(data)
        self._size = _size = 1 << (self._len - 1).bit_length()

        self.data = [default] * (2 * _size)
        self.data[_size:_size + self._len] = data
        for i in reversed(range(_size)):
            self.data[i] = func(self.data[i + i], self.data[i + i + 1])

    def __delitem__(self, idx):
        self[idx] = self._default

    def __getitem__(self, idx):
        return self.data[idx + self._size]

    def __setitem__(self, idx, value):
        idx += self._size
        self.data[idx] = value
        idx >>= 1
        while idx:
            self.data[idx] = self._func(self.data[2 * idx], self.data[2 * idx + 1])
            idx >>= 1

    def __len__(self):
        return self._len

    def query(self, start, stop):
        if start == stop:
            return self.__getitem__(start)
        stop += 1
        start += self._size
        stop += self._size

        res = self._default
        while start < stop:
            if start & 1:
                res = self._func(res, self.data[start])
                start += 1
            if stop & 1:
                stop -= 1
                res = self._func(res, self.data[stop])
            start >>= 1
            stop >>= 1
        return res

    def __repr__(self):
        return "SegmentTree({0})".format(self.data)

# -------------------------------iye ha chutiya zindegi-------------------------------------
class Factorial:
    def __init__(self, MOD):
        self.MOD = MOD
        self.factorials = [1, 1]
        self.invModulos = [0, 1]
        self.invFactorial_ = [1, 1]

    def calc(self, n):
        if n <= -1:
            print("Invalid argument to calculate n!")
            print("n must be non-negative value. But the argument was " + str(n))
            exit()
        if n < len(self.factorials):
            return self.factorials[n]
        nextArr = [0] * (n + 1 - len(self.factorials))
        initialI = len(self.factorials)
        prev = self.factorials[-1]
        m = self.MOD
        for i in range(initialI, n + 1):
            prev = nextArr[i - initialI] = prev * i % m
        self.factorials += nextArr
        return self.factorials[n]

    def inv(self, n):
        if n <= -1:
            print("Invalid argument to calculate n^(-1)")
            print("n must be non-negative value. But the argument was " + str(n))
            exit()
        p = self.MOD
        pi = n % p
        if pi < len(self.invModulos):
            return self.invModulos[pi]
        nextArr = [0] * (n + 1 - len(self.invModulos))
        initialI = len(self.invModulos)
        for i in range(initialI, min(p, n + 1)):
            next = -self.invModulos[p % i] * (p // i) % p
            self.invModulos.append(next)
        return self.invModulos[pi]

    def invFactorial(self, n):
        if n <= -1:
            print("Invalid argument to calculate (n^(-1))!")
            print("n must be non-negative value. But the argument was " + str(n))
            exit()
        if n < len(self.invFactorial_):
            return self.invFactorial_[n]
        self.inv(n)  # To make sure already calculated n^-1
        nextArr = [0] * (n + 1 - len(self.invFactorial_))
        initialI = len(self.invFactorial_)
        prev = self.invFactorial_[-1]
        p = self.MOD
        for i in range(initialI, n + 1):
            prev = nextArr[i - initialI] = (prev * self.invModulos[i % p]) % p
        self.invFactorial_ += nextArr
        return self.invFactorial_[n]

class Combination:
    def __init__(self, MOD):
        self.MOD = MOD
        self.factorial = Factorial(MOD)

    def ncr(self, n, k):
        if k < 0 or n < k:
            return 0
        k = min(k, n - k)
        f = self.factorial
        return f.calc(n) * f.invFactorial(max(n - k, k)) * f.invFactorial(min(k, n - k)) % self.MOD

# --------------------------------------iye ha combinations ka zindegi---------------------------------
def powm(a, n, m):
    if a == 1 or n == 0:
        return 1
    if n % 2 == 0:
        s = powm(a, n // 2, m)
        return s * s % m
    else:
        return a * powm(a, n - 1, m) % m

# --------------------------------------iye ha power ka zindegi---------------------------------
def sort_list(list1, list2):
    zipped_pairs = zip(list2, list1)

    z = [x for _, x in sorted(zipped_pairs)]

    return z

# --------------------------------------------------product----------------------------------------
def product(l):
    por = 1
    for i in range(len(l)):
        por *= l[i]
    return por

# --------------------------------------------------binary----------------------------------------
def binarySearchCount(arr, n, key):
    left = 0
    right = n - 1

    count = 0

    while (left <= right):
        mid = int((right + left) / 2)

        # Check if middle element is
        # less than or equal to key
        if (arr[mid] <=key):
            count = mid + 1
            left = mid + 1

        # If key is smaller, ignore right half
        else:
            right = mid - 1

    return count

# --------------------------------------------------binary----------------------------------------
def countdig(n):
    c = 0
    while (n > 0):
        n //= 10
        c += 1
    return c
def binary(x, length):
    y = bin(x)[2:]
    return y if len(y) >= length else "0" * (length - len(y)) + y

def countGreater(arr, n, k):
    l = 0
    r = n - 1

    # Stores the index of the left most element
    # from the array which is greater than k
    leftGreater = n

    # Finds number of elements greater than k
    while (l <= r):
        m = int(l + (r - l) / 2)
        if (arr[m] > k):
            leftGreater = m
            r = m - 1

        # If mid element is less than
        # or equal to k update l
        else:
            l = m + 1

    # Return the count of elements
    # greater than k
    return (n - leftGreater)

# --------------------------------------------------binary------------------------------------
class TrieNode:
    def __init__(self):
        self.children = [None] * 26
        self.isEndOfWord = False
class Trie:
    def __init__(self):
        self.root = self.getNode()
    def getNode(self):
        return TrieNode()
    def _charToIndex(self, ch):
        return ord(ch) - ord('a')
    def insert(self, key):
        pCrawl = self.root
        length = len(key)
        for level in range(length):
            index = self._charToIndex(key[level])
            if not pCrawl.children[index]:
                pCrawl.children[index] = self.getNode()
            pCrawl = pCrawl.children[index]
        pCrawl.isEndOfWord = True
    def search(self, key):
        pCrawl = self.root
        length = len(key)
        for level in range(length):
            index = self._charToIndex(key[level])
            if not pCrawl.children[index]:
                return False
            pCrawl = pCrawl.children[index]
        return pCrawl != None and pCrawl.isEndOfWord
#-----------------------------------------trie---------------------------------
class Node:
    def __init__(self, data):
        self.data = data
        self.count=0
        self.left = None  # left node for 0
        self.right = None  # right node for 1
class BinaryTrie:
    def __init__(self):
        self.root = Node(0)
    def insert(self, pre_xor):
        self.temp = self.root
        for i in range(31, -1, -1):
            val = pre_xor & (1 << i)
            if val:
                if not self.temp.right:
                    self.temp.right = Node(0)
                self.temp = self.temp.right
                self.temp.count+=1
            if not val:
                if not self.temp.left:
                    self.temp.left = Node(0)
                self.temp = self.temp.left
                self.temp.count += 1
        self.temp.data = pre_xor
    def query(self, xor):
        self.temp = self.root
        for i in range(31, -1, -1):
            val = xor & (1 << i)
            if not val:
                if self.temp.left and self.temp.left.count>0:
                    self.temp = self.temp.left
                elif self.temp.right:
                    self.temp = self.temp.right
            else:
                if self.temp.right and self.temp.right.count>0:
                    self.temp = self.temp.right
                elif self.temp.left:
                    self.temp = self.temp.left
            self.temp.count-=1
        return xor ^ self.temp.data
#-------------------------bin trie-------------------------------------------
n=int(input())
for i in range(2000,1,-1):
    if (n+i)%(i-1)==0:
        print(i)
        l=[0]*(i-2)+[-1]+[(n+i)//(i-1)]
        print(*l)
        sys.exit(0)
print(-1)


# ---------------------------iye ha aam zindegi---------------------------------------------
import math
import random
import heapq, bisect
import sys
from collections import deque, defaultdict
from fractions import Fraction
import sys
import threading
from collections import defaultdict
#threading.stack_size(10**8)
mod = 10 ** 9 + 7
mod1 = 998244353

# ------------------------------warmup----------------------------
import os
import sys
from io import BytesIO, IOBase
#sys.setrecursionlimit(300000)

BUFSIZE = 8192

class FastIO(IOBase):
    newlines = 0

    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()

    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)

class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")

sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)
input = lambda: sys.stdin.readline().rstrip("\r\n")

# -------------------game starts now----------------------------------------------------import math
class TreeNode:
    def __init__(self, k, v):
        self.key = k
        self.value = v
        self.left = None
        self.right = None
        self.parent = None
        self.height = 1
        self.num_left = 1
        self.num_total = 1

class AvlTree:

    def __init__(self):
        self._tree = None

    def add(self, k, v):
        if not self._tree:
            self._tree = TreeNode(k, v)
            return
        node = self._add(k, v)
        if node:
            self._rebalance(node)

    def _add(self, k, v):
        node = self._tree
        while node:
            if k < node.key:
                if node.left:
                    node = node.left
                else:
                    node.left = TreeNode(k, v)
                    node.left.parent = node
                    return node.left
            elif node.key < k:
                if node.right:
                    node = node.right
                else:
                    node.right = TreeNode(k, v)
                    node.right.parent = node
                    return node.right
            else:
                node.value = v
                return

    @staticmethod
    def get_height(x):
        return x.height if x else 0

    @staticmethod
    def get_num_total(x):
        return x.num_total if x else 0

    def _rebalance(self, node):

        n = node
        while n:
            lh = self.get_height(n.left)
            rh = self.get_height(n.right)
            n.height = max(lh, rh) + 1
            balance_factor = lh - rh
            n.num_total = 1 + self.get_num_total(n.left) + self.get_num_total(n.right)
            n.num_left = 1 + self.get_num_total(n.left)

            if balance_factor > 1:
                if self.get_height(n.left.left) < self.get_height(n.left.right):
                    self._rotate_left(n.left)
                self._rotate_right(n)
            elif balance_factor < -1:
                if self.get_height(n.right.right) < self.get_height(n.right.left):
                    self._rotate_right(n.right)
                self._rotate_left(n)
            else:
                n = n.parent

    def _remove_one(self, node):
        """
        Side effect!!! Changes node. Node should have exactly one child
        """
        replacement = node.left or node.right
        if node.parent:
            if AvlTree._is_left(node):
                node.parent.left = replacement
            else:
                node.parent.right = replacement
            replacement.parent = node.parent
            node.parent = None
        else:
            self._tree = replacement
            replacement.parent = None
        node.left = None
        node.right = None
        node.parent = None
        self._rebalance(replacement)

    def _remove_leaf(self, node):
        if node.parent:
            if AvlTree._is_left(node):
                node.parent.left = None
            else:
                node.parent.right = None
            self._rebalance(node.parent)
        else:
            self._tree = None
        node.parent = None
        node.left = None
        node.right = None

    def remove(self, k):
        node = self._get_node(k)
        if not node:
            return
        if AvlTree._is_leaf(node):
            self._remove_leaf(node)
            return
        if node.left and node.right:
            nxt = AvlTree._get_next(node)
            node.key = nxt.key
            node.value = nxt.value
            if self._is_leaf(nxt):
                self._remove_leaf(nxt)
            else:
                self._remove_one(nxt)
            self._rebalance(node)
        else:
            self._remove_one(node)

    def get(self, k):
        node = self._get_node(k)
        return node.value if node else -1

    def _get_node(self, k):
        if not self._tree:
            return None
        node = self._tree
        while node:
            if k < node.key:
                node = node.left
            elif node.key < k:
                node = node.right
            else:
                return node
        return None

    def get_at(self, pos):
        x = pos + 1
        node = self._tree
        while node:
            if x < node.num_left:
                node = node.left
            elif node.num_left < x:
                x -= node.num_left
                node = node.right
            else:
                return (node.key, node.value)
        raise IndexError("Out of ranges")

    @staticmethod
    def _is_left(node):
        return node.parent.left and node.parent.left == node

    @staticmethod
    def _is_leaf(node):
        return node.left is None and node.right is None

    def _rotate_right(self, node):
        if not node.parent:
            self._tree = node.left
            node.left.parent = None
        elif AvlTree._is_left(node):
            node.parent.left = node.left
            node.left.parent = node.parent
        else:
            node.parent.right = node.left
            node.left.parent = node.parent
        bk = node.left.right
        node.left.right = node
        node.parent = node.left
        node.left = bk
        if bk:
            bk.parent = node
        node.height = max(self.get_height(node.left), self.get_height(node.right)) + 1
        node.num_total = 1 + self.get_num_total(node.left) + self.get_num_total(node.right)
        node.num_left = 1 + self.get_num_total(node.left)

    def _rotate_left(self, node):
        if not node.parent:
            self._tree = node.right
            node.right.parent = None
        elif AvlTree._is_left(node):
            node.parent.left = node.right
            node.right.parent = node.parent
        else:
            node.parent.right = node.right
            node.right.parent = node.parent
        bk = node.right.left
        node.right.left = node
        node.parent = node.right
        node.right = bk
        if bk:
            bk.parent = node
        node.height = max(self.get_height(node.left), self.get_height(node.right)) + 1
        node.num_total = 1 + self.get_num_total(node.left) + self.get_num_total(node.right)
        node.num_left = 1 + self.get_num_total(node.left)

    @staticmethod
    def _get_next(node):
        if not node.right:
            return node.parent
        n = node.right
        while n.left:
            n = n.left
        return n

# -----------------------------------------------binary seacrh tree---------------------------------------
class SegmentTree1:
    def __init__(self, data, default=300006, func=lambda a, b: min(a , b)):
        """initialize the segment tree with data"""
        self._default = default
        self._func = func
        self._len = len(data)
        self._size = _size = 1 << (self._len - 1).bit_length()

        self.data = [default] * (2 * _size)
        self.data[_size:_size + self._len] = data
        for i in reversed(range(_size)):
            self.data[i] = func(self.data[i + i], self.data[i + i + 1])

    def __delitem__(self, idx):
        self[idx] = self._default

    def __getitem__(self, idx):
        return self.data[idx + self._size]

    def __setitem__(self, idx, value):
        idx += self._size
        self.data[idx] = value
        idx >>= 1
        while idx:
            self.data[idx] = self._func(self.data[2 * idx], self.data[2 * idx + 1])
            idx >>= 1

    def __len__(self):
        return self._len

    def query(self, start, stop):
        if start == stop:
            return self.__getitem__(start)
        stop += 1
        start += self._size
        stop += self._size

        res = self._default
        while start < stop:
            if start & 1:
                res = self._func(res, self.data[start])
                start += 1
            if stop & 1:
                stop -= 1
                res = self._func(res, self.data[stop])
            start >>= 1
            stop >>= 1
        return res

    def __repr__(self):
        return "SegmentTree({0})".format(self.data)

# -------------------game starts now----------------------------------------------------import math
class SegmentTree:
    def __init__(self, data, default=0, func=lambda a, b:max(a , b)):
        """initialize the segment tree with data"""
        self._default = default
        self._func = func
        self._len = len(data)
        self._size = _size = 1 << (self._len - 1).bit_length()

        self.data = [default] * (2 * _size)
        self.data[_size:_size + self._len] = data
        for i in reversed(range(_size)):
            self.data[i] = func(self.data[i + i], self.data[i + i + 1])

    def __delitem__(self, idx):
        self[idx] = self._default

    def __getitem__(self, idx):
        return self.data[idx + self._size]

    def __setitem__(self, idx, value):
        idx += self._size
        self.data[idx] = value
        idx >>= 1
        while idx:
            self.data[idx] = self._func(self.data[2 * idx], self.data[2 * idx + 1])
            idx >>= 1

    def __len__(self):
        return self._len

    def query(self, start, stop):
        if start == stop:
            return self.__getitem__(start)
        stop += 1
        start += self._size
        stop += self._size

        res = self._default
        while start < stop:
            if start & 1:
                res = self._func(res, self.data[start])
                start += 1
            if stop & 1:
                stop -= 1
                res = self._func(res, self.data[stop])
            start >>= 1
            stop >>= 1
        return res

    def __repr__(self):
        return "SegmentTree({0})".format(self.data)

# -------------------------------iye ha chutiya zindegi-------------------------------------
class Factorial:
    def __init__(self, MOD):
        self.MOD = MOD
        self.factorials = [1, 1]
        self.invModulos = [0, 1]
        self.invFactorial_ = [1, 1]

    def calc(self, n):
        if n <= -1:
            print("Invalid argument to calculate n!")
            print("n must be non-negative value. But the argument was " + str(n))
            exit()
        if n < len(self.factorials):
            return self.factorials[n]
        nextArr = [0] * (n + 1 - len(self.factorials))
        initialI = len(self.factorials)
        prev = self.factorials[-1]
        m = self.MOD
        for i in range(initialI, n + 1):
            prev = nextArr[i - initialI] = prev * i % m
        self.factorials += nextArr
        return self.factorials[n]

    def inv(self, n):
        if n <= -1:
            print("Invalid argument to calculate n^(-1)")
            print("n must be non-negative value. But the argument was " + str(n))
            exit()
        p = self.MOD
        pi = n % p
        if pi < len(self.invModulos):
            return self.invModulos[pi]
        nextArr = [0] * (n + 1 - len(self.invModulos))
        initialI = len(self.invModulos)
        for i in range(initialI, min(p, n + 1)):
            next = -self.invModulos[p % i] * (p // i) % p
            self.invModulos.append(next)
        return self.invModulos[pi]

    def invFactorial(self, n):
        if n <= -1:
            print("Invalid argument to calculate (n^(-1))!")
            print("n must be non-negative value. But the argument was " + str(n))
            exit()
        if n < len(self.invFactorial_):
            return self.invFactorial_[n]
        self.inv(n)  # To make sure already calculated n^-1
        nextArr = [0] * (n + 1 - len(self.invFactorial_))
        initialI = len(self.invFactorial_)
        prev = self.invFactorial_[-1]
        p = self.MOD
        for i in range(initialI, n + 1):
            prev = nextArr[i - initialI] = (prev * self.invModulos[i % p]) % p
        self.invFactorial_ += nextArr
        return self.invFactorial_[n]

class Combination:
    def __init__(self, MOD):
        self.MOD = MOD
        self.factorial = Factorial(MOD)

    def ncr(self, n, k):
        if k < 0 or n < k:
            return 0
        k = min(k, n - k)
        f = self.factorial
        return f.calc(n) * f.invFactorial(max(n - k, k)) * f.invFactorial(min(k, n - k)) % self.MOD

# --------------------------------------iye ha combinations ka zindegi---------------------------------
def powm(a, n, m):
    if a == 1 or n == 0:
        return 1
    if n % 2 == 0:
        s = powm(a, n // 2, m)
        return s * s % m
    else:
        return a * powm(a, n - 1, m) % m

# --------------------------------------iye ha power ka zindegi---------------------------------
def sort_list(list1, list2):
    zipped_pairs = zip(list2, list1)

    z = [x for _, x in sorted(zipped_pairs)]

    return z

# --------------------------------------------------product----------------------------------------
def product(l):
    por = 1
    for i in range(len(l)):
        por *= l[i]
    return por

# --------------------------------------------------binary----------------------------------------
def binarySearchCount(arr, n, key):
    left = 0
    right = n - 1

    count = 0

    while (left <= right):
        mid = int((right + left) / 2)

        # Check if middle element is
        # less than or equal to key
        if (arr[mid] <=key):
            count = mid + 1
            left = mid + 1

        # If key is smaller, ignore right half
        else:
            right = mid - 1

    return count

# --------------------------------------------------binary----------------------------------------
def countdig(n):
    c = 0
    while (n > 0):
        n //= 10
        c += 1
    return c
def binary(x, length):
    y = bin(x)[2:]
    return y if len(y) >= length else "0" * (length - len(y)) + y

def countGreater(arr, n, k):
    l = 0
    r = n - 1

    # Stores the index of the left most element
    # from the array which is greater than k
    leftGreater = n

    # Finds number of elements greater than k
    while (l <= r):
        m = int(l + (r - l) / 2)
        if (arr[m] > k):
            leftGreater = m
            r = m - 1

        # If mid element is less than
        # or equal to k update l
        else:
            l = m + 1

    # Return the count of elements
    # greater than k
    return (n - leftGreater)

# --------------------------------------------------binary------------------------------------
class TrieNode:
    def __init__(self):
        self.children = [None] * 26
        self.isEndOfWord = False
class Trie:
    def __init__(self):
        self.root = self.getNode()
    def getNode(self):
        return TrieNode()
    def _charToIndex(self, ch):
        return ord(ch) - ord('a')
    def insert(self, key):
        pCrawl = self.root
        length = len(key)
        for level in range(length):
            index = self._charToIndex(key[level])
            if not pCrawl.children[index]:
                pCrawl.children[index] = self.getNode()
            pCrawl = pCrawl.children[index]
        pCrawl.isEndOfWord = True
    def search(self, key):
        pCrawl = self.root
        length = len(key)
        for level in range(length):
            index = self._charToIndex(key[level])
            if not pCrawl.children[index]:
                return False
            pCrawl = pCrawl.children[index]
        return pCrawl != None and pCrawl.isEndOfWord
#-----------------------------------------trie---------------------------------
class Node:
    def __init__(self, data):
        self.data = data
        self.count=0
        self.left = None  # left node for 0
        self.right = None  # right node for 1
class BinaryTrie:
    def __init__(self):
        self.root = Node(0)
    def insert(self, pre_xor):
        self.temp = self.root
        for i in range(31, -1, -1):
            val = pre_xor & (1 << i)
            if val:
                if not self.temp.right:
                    self.temp.right = Node(0)
                self.temp = self.temp.right
                self.temp.count+=1
            if not val:
                if not self.temp.left:
                    self.temp.left = Node(0)
                self.temp = self.temp.left
                self.temp.count += 1
        self.temp.data = pre_xor
    def query(self, xor):
        self.temp = self.root
        for i in range(31, -1, -1):
            val = xor & (1 << i)
            if not val:
                if self.temp.left and self.temp.left.count>0:
                    self.temp = self.temp.left
                elif self.temp.right:
                    self.temp = self.temp.right
            else:
                if self.temp.right and self.temp.right.count>0:
                    self.temp = self.temp.right
                elif self.temp.left:
                    self.temp = self.temp.left
            self.temp.count-=1
        return xor ^ self.temp.data
#-------------------------bin trie-------------------------------------------
k=int(input())
print(2000)
su=k+1999+1
s=[-1]
while(su>0):
    s.append(min(su,1000000))
    su-=min(su,1000000)
s+=[0]*(2000-len(s))
print(*s)


k=int(input())
ans=[-1]
while sum(ans)-len(ans)+1!=k:
	ans.append(min(10**6,k+len(ans)-sum(ans)))
print(len(ans))
print(*ans)


k=int(input())
ans=[-1]
while sum(ans)-len(ans)+1!=k:
	ans.append(min(10**6,k+len(ans)-sum(ans)))
print(*ans)


import java.util.Scanner;

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author Andy Phan
 */
public class p001130e {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        if(n < 1e6) System.out.println(1 + "\n" + -n);
        else {
            System.out.println(2000);
            for(int i = 0; i < 1998; i++) System.out.print("0 ");
            int y = (1999-n%1999)%1999;
            System.out.print(-y + " ");
            System.out.println((n+2000*y)/1999);
        }
    }
}


import java.util.Scanner;

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author Andy Phan
 */
public class p1130e {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        System.out.println("2");
        System.out.println("-1 " + (n+1));
    }
}


import java.util.Scanner;

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author Andy Phan
 */
public class p1130e {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        if(n < 1e6) System.out.println(2 + "\n" + -n + " " + -n);
        else {
                for(int i = 2; i <= 2000; i++) {
                    for(int j = 1; j <= i; j++) {
                        if((i+n)%j == 0 && ((i+n)/j)/i < 1_000_000) {
                            int tot = (i+n)/j;
                            System.out.println(i);
                            int num = 0;
                            for(int k = 0; tot >= 1_000_000; k++) {
                                tot -= 1_000_000;
                                System.out.print(1_000_000 + " ");
                                num++;
                            }
                            num++;
                            System.out.println(tot);
                            for(int k = num; k < i-j; k++) {
                                System.out.println("0 ");
                            }
                            for(int k = 0; i < j; k++) {
                                if(k%0 == 0) System.out.print("-1 "); else System.out.print("1 ");
                            }
                            return;
                        }
                    }
                }
                System.out.println("-1");
            }

    }
}


import java.util.Scanner;

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author Andy Phan
 */
public class p1130e {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        if(n < 1e6) System.out.println(2 + "\n" + -n + " " + -n);
        else {
            if(n%2 == 0) System.out.println(4 + "\n" + n/2 + " " + n/2 + " -1 1");
            else {
                for(int i = 2; i <= 2000; i++) {
                    for(int j = 1; j <= i; j+=3) {
                        if((i+n)%j == 0 && ((i+n)/j)/i < 1_000_000) {
                            int tot = (i+n)/j;
                            System.out.println(i);
                            int num = 0;
                            for(int k = 0; tot >= 1_000_000; k++) {
                                tot -= 1_000_000;
                                System.out.print(1_000_000 + " ");
                                num++;
                            }
                            num++;
                            System.out.println(tot);
                            for(int k = num; k < i-j; k++) {
                                System.out.println("0 ");
                            }
                            for(int k = 0; i < j; k++) {
                                if(k%0 == 0) System.out.print("-1 "); else System.out.print("1 ");
                            }
                            return;
                        }
                    }
                }
                System.out.println("-1");
            }
        }
    }
}


import java.util.Scanner;

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author Andy Phan
 */
public class p1130e {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        if(n < 1e6) System.out.println(2 + "\n" + -n + " " + -n);
        else {
                for(int i = 2; i <= 2000; i++) {
                    for(int j = 1; j < i; j++) {
                        if((i+n)%j == 0 && ((i+n)/j)/i < 1_000_000) {
                            int tot = (i+n)/j;
                            String res = i+"\n";
                            int num = 0;
                            for(int k = 0; tot >= 1_000_000; k++) {
                                tot -= 1_000_000;
                                res += 1_000_000+" ";
                                num++;
                            }
                            num++;
                            res += tot + " ";
                            for(int k = num; k < i-j; k++) {
                                res += "0 ";
                            }
                            for(int k = i-j; k < i; k++) {
                                if(k%2 == 0) res += "-1 "; else res += "1 ";
                            }
                            System.out.println(res);
                            return;
                        }
                    }
                }
                System.out.println("-1");
            }

    }
}


import java.util.Scanner;

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 *
 * @author Andy Phan
 */
public class p1130e {
    public static void main(String[] args) {
        Scanner in = new Scanner(System.in);
        int n = in.nextInt();
        System.out.println("2");
        System.out.println("-1 " + (n+2));
    }
}


import java.io.File;
import java.io.FileNotFoundException;
import java.util.Scanner;

public class B542 {

    private final static Integer N = 2000;
//    private final static Integer N = 5;
    private final static Integer MAX_VAL = 1000000;

    public static void main(String[] args) throws FileNotFoundException {
//        final File inFile = new File("resources/B542.in");
        final Scanner scanner = new Scanner(System.in);

        final Integer K = scanner.nextInt();
        Integer S = K + N - 1;

        System.out.println(N);
        System.out.print("-1 ");
        S += 1;
        for (int i = 1 ; i < N ; i++) {
            if((N - i - 1) > 0 && (N - i - 1)* MAX_VAL < S) {
                System.out.print(MAX_VAL + " ");
                S -= MAX_VAL;
            } else if((N - i - 1) > 0 && (N - i - 1) > S) {
                System.out.print("1 ");
                S -= 1;
            } else {
                //this should be terminal
                System.out.print((S - (N - i - 1)) + " ");
                S = (N - i - 1);
            }
        }
        System.out.print("\n");
    }
}