#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int,int> ii;
#define f first
#define s second
int main(){
	ios_base::sync_with_stdio(0); cin.tie(0);
	int n,k;
	cin>>n>>k;
	if (n*(n+1)/2 < k) cout<<"no solution\n";
	else for (int i=0;i<n;i++) cout<<"0 "<<i<<'\n';
	return 0;
}


#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int,int> ii;
#define f first
#define s second
int main(){
	ios_base::sync_with_stdio(0); cin.tie(0);
	int n,k;
	cin>>n>>k;
	if (n*(n-1)/2 <= k) cout<<"no solution\n";
	else for (int i=0;i<n;i++) cout<<"0 "<<i<<'\n';
	return 0;
}


#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int,int> ii;
#define f first
#define s second
int main(){
	ios_base::sync_with_stdio(0); cin.tie(0);
	int n,k;
	cin>>n>>k;
	if (n*(n-1)/2 < k) cout<<"no solution\n";
	else for (int i=0;i<n;i++) cout<<"0 "<<i<<'\n';
	return 0;
}


#include<bits/stdc++.h>
#define rep(i,a,b) for(ll i=a;i<b;++i)
#define ll long long
#define M 998244353
#define all(v) (v).begin(),(v).end()
#define fr first
#define sc second
#define sz(x) (ll)((x).size())
#define endl "\n"
#define vc vector
#define pb push_back
#define pii pair<ll,ll>
#define psi pair<string,ll>
#define mii map<ll,ll>
#define mp  make_pair
#define fast ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0);
#define PI 3.14159265
#define r0 return
const long long INF=1e18;
using namespace std;
void solve()
{
	ll n,k; cin>>n>>k;
	if((n*(n-1))/2<=k) {cout<<"no solution"; r0;}
	rep(i,0,n)
		cout<<i<<" "<<i<<endl;
}
int main()
{
	fast
	ll t=1;
	//cin>>t;
	while(t--)
	{
		solve();
	}
}


#include<bits/stdc++.h>
#define rep(i,a,b) for(ll i=a;i<b;++i)
#define ll long long
#define M 998244353
#define all(v) (v).begin(),(v).end()
#define fr first
#define sc second
#define sz(x) (ll)((x).size())
#define endl "\n"
#define vc vector
#define pb push_back
#define pii pair<ll,ll>
#define psi pair<string,ll>
#define mii map<ll,ll>
#define mp  make_pair
#define fast ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0);
#define PI 3.14159265
#define r0 return
const long long INF=1e18;
using namespace std;
void solve()
{
	ll n,k; cin>>n>>k;
	if((n*(n-1))/2<=k) {cout<<"no solution"; r0;}
	rep(i,0,n)
		cout<<0<<" "<<i<<endl;
}
int main()
{
	fast
	ll t=1;
	//cin>>t;
	while(t--)
	{
		solve();
	}
}


#define __USE_MINGW_ANSI_STDIO 0
#include <bits/stdc++.h>
#define IOS ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
#define endl '\n'
#define ff first
#define ss second
#define mod 1000000007
#define pb push_back
#define mp make_pair
#define int long long
#define all(a) a.begin(), a.end()
#define inf (1LL<<61)
#define print_time cerr << "Time elapsed: " << 1000.0 * clock() / CLOCKS_PER_SEC << "ms\n";
#define ull unsigned long long
#define debug1(x) cerr << #x << ": " << x <<'\n'
#define debug2(x, y) cerr << #x << ": " << x << '\t' << #y << ": " << y <<'\n'
#define debug3(x, y, z) cerr << #x << ": " << x << '\t' << #y << ": " << y << '\t' << #z << ": " << z <<'\n'
using namespace std;
int dx[]={1,0,-1,0};int dy[]={0,1,0,-1}; //4 Direction
//int dx[]={1,1,0,-1,-1,-1,0,1};int dy[]={0,1,1,1,0,-1,-1,-1};//8 direction
int gcd(int x,int y)
{
    if(y==0)
	return x;
    else
	return gcd(y,x%y);
}
int expo(int n,int m,int p)   //modULAR EXPONENTIATION
{
    int r=1;
    n=n%p;
    while(m>0)
    {
	if(m%2)
	    r=(r*n)%p;
	n=(n*n)%p;
	m=m/2;
    }
    return r%p;
}
bool isPrime(int n)
{
    // Corner cases
    if (n <= 1)  return false;
    if (n <= 3)  return true;

    // This is checked so that we can skip
    // middle five numbers in below loop
    if (n%2 == 0 || n%3 == 0) return false;

    for (int i=5; i*i<=n; i=i+6)
	if (n%i == 0 || n%(i+2) == 0)
	   return false;

    return true;
}
vector<int> z_function(string s) {
    int n = (int) s.length();
    vector<int> z(n);
    for (int i = 1, l = 0, r = 0; i < n; ++i) {
	if (i <= r)
	    z[i] = min (r - i + 1, z[i - l]);
	while (i + z[i] < n && s[z[i]] == s[i + z[i]])
	    ++z[i];
	if (i + z[i] - 1 > r)
	    l = i, r = i + z[i] - 1;
    }
    return z;
}
int32_t main()
{
   IOS;
   #ifndef ONLINE_JUDGE
   freopen("input.txt","r",stdin);
   freopen("output.txt","w",stdout);
   #endif
   /********************* Code starts here ***********************/
   int n,k;
   cin>>n>>k;
   if(k<(n*(n-1))/2)
   {
   	cout<<"no solution"<<endl;
   	return 0;
   }
   for(int i=0;i<n;i++)
   {
   	cout<<"0 "<<i<<endl;
   }
}


#define __USE_MINGW_ANSI_STDIO 0
#include <bits/stdc++.h>
#define IOS ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
#define endl '\n'
#define ff first
#define ss second
#define mod 1000000007
#define pb push_back
#define mp make_pair
#define int long long
#define all(a) a.begin(), a.end()
#define inf (1LL<<61)
#define print_time cerr << "Time elapsed: " << 1000.0 * clock() / CLOCKS_PER_SEC << "ms\n";
#define ull unsigned long long
#define debug1(x) cerr << #x << ": " << x <<'\n'
#define debug2(x, y) cerr << #x << ": " << x << '\t' << #y << ": " << y <<'\n'
#define debug3(x, y, z) cerr << #x << ": " << x << '\t' << #y << ": " << y << '\t' << #z << ": " << z <<'\n'
using namespace std;
int dx[]={1,0,-1,0};int dy[]={0,1,0,-1}; //4 Direction
//int dx[]={1,1,0,-1,-1,-1,0,1};int dy[]={0,1,1,1,0,-1,-1,-1};//8 direction
int gcd(int x,int y)
{
    if(y==0)
	return x;
    else
	return gcd(y,x%y);
}
int expo(int n,int m,int p)   //modULAR EXPONENTIATION
{
    int r=1;
    n=n%p;
    while(m>0)
    {
	if(m%2)
	    r=(r*n)%p;
	n=(n*n)%p;
	m=m/2;
    }
    return r%p;
}
bool isPrime(int n)
{
    // Corner cases
    if (n <= 1)  return false;
    if (n <= 3)  return true;

    // This is checked so that we can skip
    // middle five numbers in below loop
    if (n%2 == 0 || n%3 == 0) return false;

    for (int i=5; i*i<=n; i=i+6)
	if (n%i == 0 || n%(i+2) == 0)
	   return false;

    return true;
}
vector<int> z_function(string s) {
    int n = (int) s.length();
    vector<int> z(n);
    for (int i = 1, l = 0, r = 0; i < n; ++i) {
	if (i <= r)
	    z[i] = min (r - i + 1, z[i - l]);
	while (i + z[i] < n && s[z[i]] == s[i + z[i]])
	    ++z[i];
	if (i + z[i] - 1 > r)
	    l = i, r = i + z[i] - 1;
    }
    return z;
}
int32_t main()
{
   IOS;
   #ifndef ONLINE_JUDGE
   freopen("input.txt","r",stdin);
   freopen("output.txt","w",stdout);
   #endif
   /********************* Code starts here ***********************/
   int n,k;
   cin>>n>>k;
   if(k>=(n*(n-1))/2)
   {
   	cout<<"no solution"<<endl;
   	return 0;
   }
   for(int i=0;i<n;i++)
   {
   	cout<<"0 "<<i<<endl;
   }
}


#define __USE_MINGW_ANSI_STDIO 0
#include <bits/stdc++.h>
#define IOS ios::sync_with_stdio(0); cin.tie(0); cout.tie(0);
#define endl '\n'
#define ff first
#define ss second
#define mod 1000000007
#define pb push_back
#define mp make_pair
#define int long long
#define all(a) a.begin(), a.end()
#define inf (1LL<<61)
#define print_time cerr << "Time elapsed: " << 1000.0 * clock() / CLOCKS_PER_SEC << "ms\n";
#define ull unsigned long long
#define debug1(x) cerr << #x << ": " << x <<'\n'
#define debug2(x, y) cerr << #x << ": " << x << '\t' << #y << ": " << y <<'\n'
#define debug3(x, y, z) cerr << #x << ": " << x << '\t' << #y << ": " << y << '\t' << #z << ": " << z <<'\n'
using namespace std;
int dx[]={1,0,-1,0};int dy[]={0,1,0,-1}; //4 Direction
//int dx[]={1,1,0,-1,-1,-1,0,1};int dy[]={0,1,1,1,0,-1,-1,-1};//8 direction
int gcd(int x,int y)
{
    if(y==0)
	return x;
    else
	return gcd(y,x%y);
}
int expo(int n,int m,int p)   //modULAR EXPONENTIATION
{
    int r=1;
    n=n%p;
    while(m>0)
    {
	if(m%2)
	    r=(r*n)%p;
	n=(n*n)%p;
	m=m/2;
    }
    return r%p;
}
bool isPrime(int n)
{
    // Corner cases
    if (n <= 1)  return false;
    if (n <= 3)  return true;

    // This is checked so that we can skip
    // middle five numbers in below loop
    if (n%2 == 0 || n%3 == 0) return false;

    for (int i=5; i*i<=n; i=i+6)
	if (n%i == 0 || n%(i+2) == 0)
	   return false;

    return true;
}
vector<int> z_function(string s) {
    int n = (int) s.length();
    vector<int> z(n);
    for (int i = 1, l = 0, r = 0; i < n; ++i) {
	if (i <= r)
	    z[i] = min (r - i + 1, z[i - l]);
	while (i + z[i] < n && s[z[i]] == s[i + z[i]])
	    ++z[i];
	if (i + z[i] - 1 > r)
	    l = i, r = i + z[i] - 1;
    }
    return z;
}
int32_t main()
{
   IOS;
   #ifndef ONLINE_JUDGE
   freopen("input.txt","r",stdin);
   freopen("output.txt","w",stdout);
   #endif
   /********************* Code starts here ***********************/
   int n,k;
   cin>>n>>k;
   if(k>(n*(n-1))/2)
   {
   	cout<<"no solution"<<endl;
   	return 0;
   }
   for(int i=0;i<n;i++)
   {
   	cout<<"0 "<<i<<endl;
   }
}


#include <iostream>
#include <cstdio>
#include <algorithm>
#include <cstring>
#include <string>
#include <vector>
#include <map>
#include <stack>
#include <queue>
#include <set>
#include <cctype>
#define mst(a,b) memset((a),(b),sizeof(a))
#define debug printf("debug\n")
#define INF 0x3f3f3f3f
#define lson lef,mid,rt<<1
#define rson mid+1,rig,rt<<1|1
const int maxn=1e5+5;
using namespace std;
typedef long long ll;
typedef unsigned long long ull;
int main()
{
	int n,k;scanf("%d %d",&n,&k);
	if(k>(n*(n-1)/2)) puts("no solution");
	else{
		for(int i=0;i<n;i++){
			printf("%d %d\n",0,i);
		}
	}
	return 0;
}


#include <iostream>
#include <cstdio>
#include <algorithm>
#include <cstring>
#include <string>
#include <vector>
#include <map>
#include <stack>
#include <queue>
#include <set>
#include <cctype>
#define mst(a,b) memset((a),(b),sizeof(a))
#define debug printf("debug\n")
#define INF 0x3f3f3f3f
#define lson lef,mid,rt<<1
#define rson mid+1,rig,rt<<1|1
const int maxn=1e5+5;
using namespace std;
typedef long long ll;
typedef unsigned long long ull;
int main()
{
	int n,k;scanf("%d %d",&n,&k);
	if(k>=(n*(n-1)/2)) puts("no solution");
	else{
		for(int i=0;i<n;i++){
			printf("%d %d\n",0,i);
		}
	}
	return 0;
}


#include<bits/stdc++.h>

/*
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
#define ordered_set tree<int, null_type, less<int>, rb_tree_tag, tree_order_statistics_node_update>
*/

using namespace std;

/*--------------------------Containers------------------------*/
typedef     long long int           ll;
typedef     unsigned long long int  ull;
typedef     vector < int >          vi;
typedef     vector < ll >           vll;
typedef     vector < vll >           vvll;
typedef     pair< int,int >         pi;
typedef     pair< ll, ll >          pll;
typedef     vector< pi >            vpi;
typedef     vector< pll >           vpll;
/*------------------------------------------------------------*/

/*--------------------------Limits & Constants----------------*/
#define     MAX                 200007
#define     MOD                 int(1e9+9)
#define     INF                 ll(8230219982008199610)
#define     MINF                ll(-8230219982008199610)
#define     IL                  INT_MAX
#define     MIL                 INT_MIN
#define     PI                  2*acos(0.0)
/*----------------------------------
--------------------------*/

/*--------------------------Macros----------------------------*/
#define     fast                ios_base::sync_with_stdio(false);cin.tie(0); cout.tie(0)
#define     pf                  printf
#define     sc                  scanf
#define     all(a)              (a).begin(),(a).end()
#define     sz(x)               int(x.size())
#define     pb                  push_back
#define     eb                  emplace_back
#define     mp                  make_pair
#define     ff                  first
#define     ss                  second
#define     mem(a,n)            memset(a, n, sizeof(a) )
#define     gcd(a,b)            __gcd(a,b)
#define     lcm(a,b)            (a*(b/gcd(a,b)))
#define     forn(i,n)          for(int i=0; i<n; i++)
#define     loop1(i,n)          for(int i=1; i<=n; i++)
#define     rev0(i,n)           for(int i=n-1; i>=0; i--)
#define     rev1(i,n)           for(int i=n; i>0; i--)
/*------------------------------------------------------------*/

/*----------------------Scans and Prints----------------------*/
#define     sc1(x)              scanf("%d",&x)
#define     sc2(x,y)            scanf("%d %d",&x,&y)
#define     sc3(x,y,z)          scanf("%d %d %d",&x,&y,&z)
#define     scd1(x)             scanf("%lld",&x)
#define     scd2(x,y)           scanf("%lld %lld",&x,&y)
#define     pf1(x)              printf("%d\n",x)
#define     pf2(x,y)            printf("%d %d\n",x,y)
#define     pfd1(x)             printf("%lld\n",x)
#define     pfd2(x,y)           printf("%lld %lld\n",x,y)
#define     t_case(t)           for(int cs = 1; cs<=t; cs++)
#define     print(a,n)          for(int pr = 0; pr<int(n); pr++)cout<<a[pr]<<" ";cout<<endl
#define     printa(x)           cout<<x<<endl;
#define     debug               cout<<" OK "<<endl
/*------------------------------------------------------------*/

int main()
{
	ll n;
	ll k;
	cin>>n>>k;
	ll ans= n*(n-1);
	ans/=2;
	if(k>ans)
	{
		cout<<"no solution"<<endl;
		return 0;
	}
	ll x=0;
	forn(y,n)
	{
		cout<<x<<" "<<y<<endl;
	}
}


#include<bits/stdc++.h>

/*
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
#define ordered_set tree<int, null_type, less<int>, rb_tree_tag, tree_order_statistics_node_update>
*/

using namespace std;

/*--------------------------Containers------------------------*/
typedef     long long int           ll;
typedef     unsigned long long int  ull;
typedef     vector < int >          vi;
typedef     vector < ll >           vll;
typedef     vector < vll >           vvll;
typedef     pair< int,int >         pi;
typedef     pair< ll, ll >          pll;
typedef     vector< pi >            vpi;
typedef     vector< pll >           vpll;
/*------------------------------------------------------------*/

/*--------------------------Limits & Constants----------------*/
#define     MAX                 200007
#define     MOD                 int(1e9+9)
#define     INF                 ll(8230219982008199610)
#define     MINF                ll(-8230219982008199610)
#define     IL                  INT_MAX
#define     MIL                 INT_MIN
#define     PI                  2*acos(0.0)
/*----------------------------------
--------------------------*/

/*--------------------------Macros----------------------------*/
#define     fast                ios_base::sync_with_stdio(false);cin.tie(0); cout.tie(0)
#define     pf                  printf
#define     sc                  scanf
#define     all(a)              (a).begin(),(a).end()
#define     sz(x)               int(x.size())
#define     pb                  push_back
#define     eb                  emplace_back
#define     mp                  make_pair
#define     ff                  first
#define     ss                  second
#define     mem(a,n)            memset(a, n, sizeof(a) )
#define     gcd(a,b)            __gcd(a,b)
#define     lcm(a,b)            (a*(b/gcd(a,b)))
#define     forn(i,n)          for(int i=0; i<n; i++)
#define     loop1(i,n)          for(int i=1; i<=n; i++)
#define     rev0(i,n)           for(int i=n-1; i>=0; i--)
#define     rev1(i,n)           for(int i=n; i>0; i--)
/*------------------------------------------------------------*/

/*----------------------Scans and Prints----------------------*/
#define     sc1(x)              scanf("%d",&x)
#define     sc2(x,y)            scanf("%d %d",&x,&y)
#define     sc3(x,y,z)          scanf("%d %d %d",&x,&y,&z)
#define     scd1(x)             scanf("%lld",&x)
#define     scd2(x,y)           scanf("%lld %lld",&x,&y)
#define     pf1(x)              printf("%d\n",x)
#define     pf2(x,y)            printf("%d %d\n",x,y)
#define     pfd1(x)             printf("%lld\n",x)
#define     pfd2(x,y)           printf("%lld %lld\n",x,y)
#define     t_case(t)           for(int cs = 1; cs<=t; cs++)
#define     print(a,n)          for(int pr = 0; pr<int(n); pr++)cout<<a[pr]<<" ";cout<<endl
#define     printa(x)           cout<<x<<endl;
#define     debug               cout<<" OK "<<endl
/*------------------------------------------------------------*/

int main()
{
	ll n;
	ll k;
	cin>>n>>k;
	ll ans= n*(n-1);
	ans/=2;
	if(k>=ans)
	{
		cout<<"no solution"<<endl;
		return 0;
	}
	ll x=0;
	forn(y,n)
	{
		cout<<x<<" "<<y<<endl;
	}
}


/*||>>>> Praveen Ojha <<<<>>>> 10 June 2019 <<<<>>>> 23:19:53 <<<<||*/
// #pragma GCC optimize("Ofast") //(Very Fast but Inaccurate)
// #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native") //(Small operations in many loops)
// #pragma GCC optimize("unroll-loops")
// #pragma comment(linker, "/stack:200000000")
#pragma GCC optimize("O3")
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define F first
#define S second
#define mod 1000000007
#define inf 1e18+5
#define sz(x) (int)x.size()
#define PI 3.141592653589793238510
#define all(x) (x).begin(),(x).end()
#define rall(x) (x).rbegin(),(x).rend()
#define __ ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);
#define vi vector<int>
#define vpii vector<pair<int,int> >
#define vvi vector<vector<int> >
#define PRINT_TIME cerr << "Time elapsed: " << 1.0 * clock() / CLOCKS_PER_SEC << " s." <<endl;
#define sim template < class c
#define ris return * this
#define dor > debug & operator <<
#define eni(x) sim > typename   enable_if<sizeof dud<c>(0) x 1, debug&>::type operator<<(c i) {
sim > struct rge { c b, e; };
sim > rge<c> range(c i, c j) { return rge<c>{i, j}; }
sim > auto dud(c* x) -> decltype(cerr << *x, 0);
sim > char dud(...);
struct debug {
#ifdef LOCAL
~debug() { cerr << endl; }
eni(!=) cerr << boolalpha << i; ris; }
eni(==) ris << range(begin(i), end(i)); }
sim, class b dor(pair < b, c > d) {
  ris << "(" << d.first << ", " << d.second << ")";
}
sim dor(rge<c> d) {
  *this << "[";
  for (auto it = d.b; it != d.e; ++it)
    *this << ", " + 2 * (it == d.b) << *it;
  ris << "]";
}
#else
sim dor(const c&) { ris; }
#endif
};
#define imie(...) " [" << #__VA_ARGS__ ": " << (__VA_ARGS__) << "] "
typedef long double ld;
typedef pair<int,int> pii;
//Read Problems Carefully & Check for corner cases N=0,1 ?
///////////////////////////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////////////////////
const int N=1e9;
int32_t main(){__
	int n,k;
	cin>>n>>k;
	if(n*(n-1)<=2*k){
		return cout<<"no solution\n",0;
	}
	int ny=-N;
	for(int i=0;i<n;i++){
		cout<<0<<" "<<ny++<<"\n";
	}
return 0;
}


/*||>>>> Praveen Ojha <<<<>>>> 10 June 2019 <<<<>>>> 23:19:53 <<<<||*/
// #pragma GCC optimize("Ofast") //(Very Fast but Inaccurate)
// #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native") //(Small operations in many loops)
// #pragma GCC optimize("unroll-loops")
// #pragma comment(linker, "/stack:200000000")
#pragma GCC optimize("O3")
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define F first
#define S second
#define mod 1000000007
#define inf 1e18+5
#define sz(x) (int)x.size()
#define PI 3.141592653589793238510
#define all(x) (x).begin(),(x).end()
#define rall(x) (x).rbegin(),(x).rend()
#define __ ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);
#define vi vector<int>
#define vpii vector<pair<int,int> >
#define vvi vector<vector<int> >
#define PRINT_TIME cerr << "Time elapsed: " << 1.0 * clock() / CLOCKS_PER_SEC << " s." <<endl;
#define sim template < class c
#define ris return * this
#define dor > debug & operator <<
#define eni(x) sim > typename   enable_if<sizeof dud<c>(0) x 1, debug&>::type operator<<(c i) {
sim > struct rge { c b, e; };
sim > rge<c> range(c i, c j) { return rge<c>{i, j}; }
sim > auto dud(c* x) -> decltype(cerr << *x, 0);
sim > char dud(...);
struct debug {
#ifdef LOCAL
~debug() { cerr << endl; }
eni(!=) cerr << boolalpha << i; ris; }
eni(==) ris << range(begin(i), end(i)); }
sim, class b dor(pair < b, c > d) {
  ris << "(" << d.first << ", " << d.second << ")";
}
sim dor(rge<c> d) {
  *this << "[";
  for (auto it = d.b; it != d.e; ++it)
    *this << ", " + 2 * (it == d.b) << *it;
  ris << "]";
}
#else
sim dor(const c&) { ris; }
#endif
};
#define imie(...) " [" << #__VA_ARGS__ ": " << (__VA_ARGS__) << "] "
typedef long double ld;
typedef pair<int,int> pii;
//Read Problems Carefully & Check for corner cases N=0,1 ?
///////////////////////////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////////////////////
const int N=1e9;
int32_t main(){__
	int n,k;
	cin>>n>>k;
	if(n*(n-1)<=2*k){
		return cout<<"no solution\n",0;
	}
	int nx=-N,ny=-N;
	cout<<nx<<" "<<ny<<"\n";
	cout<<nx++<<" "<<-ny<<"\n";
	for(int i=0;i<n-2;i++){
		cout<<nx++<<" "<<ny<<"\n";
	}
return 0;
}


/*||>>>> Praveen Ojha <<<<>>>> 10 June 2019 <<<<>>>> 23:19:53 <<<<||*/
// #pragma GCC optimize("Ofast") //(Very Fast but Inaccurate)
// #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native") //(Small operations in many loops)
// #pragma GCC optimize("unroll-loops")
// #pragma comment(linker, "/stack:200000000")
#pragma GCC optimize("O3")
#include <bits/stdc++.h>
using namespace std;
#define int long long
#define F first
#define S second
#define mod 1000000007
#define inf 1e18+5
#define sz(x) (int)x.size()
#define PI 3.141592653589793238510
#define all(x) (x).begin(),(x).end()
#define rall(x) (x).rbegin(),(x).rend()
#define __ ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);
#define vi vector<int>
#define vpii vector<pair<int,int> >
#define vvi vector<vector<int> >
#define PRINT_TIME cerr << "Time elapsed: " << 1.0 * clock() / CLOCKS_PER_SEC << " s." <<endl;
#define sim template < class c
#define ris return * this
#define dor > debug & operator <<
#define eni(x) sim > typename   enable_if<sizeof dud<c>(0) x 1, debug&>::type operator<<(c i) {
sim > struct rge { c b, e; };
sim > rge<c> range(c i, c j) { return rge<c>{i, j}; }
sim > auto dud(c* x) -> decltype(cerr << *x, 0);
sim > char dud(...);
struct debug {
#ifdef LOCAL
~debug() { cerr << endl; }
eni(!=) cerr << boolalpha << i; ris; }
eni(==) ris << range(begin(i), end(i)); }
sim, class b dor(pair < b, c > d) {
  ris << "(" << d.first << ", " << d.second << ")";
}
sim dor(rge<c> d) {
  *this << "[";
  for (auto it = d.b; it != d.e; ++it)
    *this << ", " + 2 * (it == d.b) << *it;
  ris << "]";
}
#else
sim dor(const c&) { ris; }
#endif
};
#define imie(...) " [" << #__VA_ARGS__ ": " << (__VA_ARGS__) << "] "
typedef long double ld;
typedef pair<int,int> pii;
//Read Problems Carefully & Check for corner cases N=0,1 ?
///////////////////////////////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////////////////////////

int32_t main(){__
	int n,k;
	cin>>n>>k;
	if(n*(n-1)<=2*k){
		return cout<<"no solution\n",0;
	}
	int nn=1000000000;
	for(int i=0;i<n;i++){
		cout<<nn--<<" "<<"0\n";
	}
return 0;
}


#include <bits/stdc++.h>
using namespace std;
#define FAST std::ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0);
#define endl '\n'
#define pb push_back
#define mod 1000000007
#define fr(i,n) for(int i=0;i<n;i++)
#define int long long int
signed main()
{
    FAST
    //freopen("input.txt","r",stdin);
    //freopen("output.txt","w",stdout);
    int n,k;
    cin>>n>>k;

    if(k>=2*n-3) {cout<<"no solution"; return 0;}

    fr(i,n)
        cout<<0<<" "<<i<<endl;

    return 0;
}


#include <bits/stdc++.h>
using namespace std;
#define FAST std::ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0);
#define endl '\n'
#define pb push_back
#define mod 1000000007
#define fr(i,n) for(int i=0;i<n;i++)
#define int long long int
signed main()
{
    FAST
    //freopen("input.txt","r",stdin);
    //freopen("output.txt","w",stdout);
    int n,k;
    cin>>n>>k;

    if(k>=n*(n-1)/2) {cout<<"no solution"; return 0;}

    fr(i,n)
        cout<<0<<" "<<i<<endl;

    return 0;
}


#include <bits/stdc++.h>
using namespace std;
#define FAST std::ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0);
#define endl '\n'
#define pb push_back
#define mod 1000000007
#define fr(i,n) for(int i=0;i<n;i++)
#define int long long int
signed main()
{
    FAST
    //freopen("input.txt","r",stdin);
    //freopen("output.txt","w",stdout);
    int n,k;
    cin>>n>>k;
    if(k>3*n-6) {cout<<"no solution"; return 0;}

    int x=n/3;
    int y=n%3;

    int i=0;
    for(;i<x;i++)
    {
        cout<<i<<" "<<i<<endl;
        cout<<i<<" "<<i+1<<endl;
        cout<<i+1<<" "<<i<<endl;
    }

    if(y==1)
    {
        cout<<i<<" "<<i;
    }
    if(y==2)
    {
        cout<<i<<" "<<i+1;
    }
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
#define FAST std::ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0);
#define endl '\n'
#define pb push_back
#define mod 1000000007
#define fr(i,n) for(int i=0;i<n;i++)
#define int long long int
signed main()
{
    FAST
    //freopen("input.txt","r",stdin);
    //freopen("output.txt","w",stdout);
    int n,k;
    cin>>n>>k;
    if(k>3*n-6) {cout<<"no solution"; return 0;}

    int x=n/3;
    int y=n%3;

    int i=0;
    for(;i<x;i++)
    {
        cout<<i<<" "<<i<<endl;
        cout<<i<<" "<<i+1<<endl;
        cout<<i+1<<" "<<i<<endl;
    }

    if(y==1)
    {
        cout<<i<<" "<<i;
    }
    if(y==2)
    {
        cout<<i<<" "<<i;
        cout<<i<<" "<<i+1;
    }
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
#define FAST std::ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0);
#define endl '\n'
#define pb push_back
#define mod 1000000007
#define fr(i,n) for(int i=0;i<n;i++)
#define int long long int
signed main()
{
    FAST
    //freopen("input.txt","r",stdin);
    //freopen("output.txt","w",stdout);
    int n,k;
    cin>>n>>k;

    int x=n/3;
    int y=n%3;

    if(k>8*x+y*3) {cout<<"no solution"; return 0;}

    int i=0;
    for(;i<x;i++)
    {
        cout<<i<<" "<<i<<endl;
        cout<<i<<" "<<i+1<<endl;
        cout<<i+1<<" "<<i<<endl;
    }

    if(y==1)
    {
        cout<<i<<" "<<i;
    }
    if(y==2)
    {
        cout<<i<<" "<<i<<endl;
        cout<<i<<" "<<i+1;
    }
    return 0;
}


#include<bits/stdc++.h>
#include<math.h>
#define ll long long
#define M 1000000007
#define pll pair<ll,ll>
#define mp make_pair
#define rep(i,a,b) for(ll i=a;i<b;i++)
#define sep(i,a,b) for(ll i=a;i>=b;i--)
#define mll map<ll,ll>
#define vl vector<ll>
#define pb push_back
#define lb lower_bound
#define ub upper_bound
#define all(a) a.begin(),a.end()
#define F first
#define S second
#include<string>
#define PI  3.14159265358979323846
using namespace std;
int main()
{
    ll n,k;
    cin>>n>>k;
    if(k >=(n*(n-1))/2) cout<<"no solution"<<endl;
    else
    {
        vector<pll> ans;
        ans.pb({0,0});
        for(ll i=2;i<=(n*2-4) && i>=0;i+=2)
        {
            ans.pb({0,i});
        }
        ans.pb({1,0});
       // ans.pb({1,1});

        rep(i,0,n)
        {
            cout<<ans[i].F<<" "<<ans[i].S<<endl;
        }
    }
}


#include<bits/stdc++.h>
#include<math.h>
#define ll long long
#define M 1000000007
#define pll pair<ll,ll>
#define mp make_pair
#define rep(i,a,b) for(ll i=a;i<b;i++)
#define sep(i,a,b) for(ll i=a;i>=b;i--)
#define mll map<ll,ll>
#define vl vector<ll>
#define pb push_back
#define lb lower_bound
#define ub upper_bound
#define all(a) a.begin(),a.end()
#define F first
#define S second
#include<string>
#define PI  3.14159265358979323846
using namespace std;
int main()
{
    ll n,k;
    cin>>n>>k;
    if(k > (n*(n-1))/2) cout<<"no solution"<<endl;
    else
    {
        vector<pll> ans;
        ans.pb({0,0});
        rep(i,0,n-3)
        {
            ans.pb({0,2+i});
        }
        ans.pb({1,0});
        ans.pb({1,1});

        rep(i,0,n)
        {
            cout<<ans[i].F<<" "<<ans[i].S<<endl;
        }
    }
}


#include<bits/stdc++.h>
#include<math.h>
#define ll long long
#define M 1000000007
#define pll pair<ll,ll>
#define mp make_pair
#define rep(i,a,b) for(ll i=a;i<b;i++)
#define sep(i,a,b) for(ll i=a;i>=b;i--)
#define mll map<ll,ll>
#define vl vector<ll>
#define pb push_back
#define lb lower_bound
#define ub upper_bound
#define all(a) a.begin(),a.end()
#define F first
#define S second
#include<string>
#define PI  3.14159265358979323846
using namespace std;
int main()
{
    ll n,k;
    cin>>n>>k;
    if(k >=(n*(n-1))/2) cout<<"no solution"<<endl;
    else
    {
        vector<pll> ans;
        ans.pb({0,0});
        rep(i,0,n-3)
        {
            ans.pb({0,2+i});
        }
        ans.pb({1,0});
        ans.pb({1,1});

        rep(i,0,n)
        {
            cout<<ans[i].F<<" "<<ans[i].S<<endl;
        }
    }
}


#include<bits/stdc++.h>
#include<math.h>
#define ll long long
#define M 1000000007
#define pll pair<ll,ll>
#define mp make_pair
#define rep(i,a,b) for(ll i=a;i<b;i++)
#define sep(i,a,b) for(ll i=a;i>=b;i--)
#define mll map<ll,ll>
#define vl vector<ll>
#define pb push_back
#define lb lower_bound
#define ub upper_bound
#define all(a) a.begin(),a.end()
#define F first
#define S second
#include<string>
#define PI  3.14159265358979323846
using namespace std;
int main()
{
    ll n,k;
    cin>>n>>k;
    if(k > =(n*(n-1))/2) cout<<"no solution"<<endl;
    else
    {
        vector<pll> ans;
        ans.pb({0,0});
        rep(i,0,n-3)
        {
            ans.pb({0,2+i});
        }
        ans.pb({1,0});
        ans.pb({1,1});

        rep(i,0,n)
        {
            cout<<ans[i].F<<" "<<ans[i].S<<endl;
        }
    }
}


#include<bits/stdc++.h>
#define ll long long
using namespace std;
ll x[2005],y[2005];
ll dist(ll i,ll j)
{
	return (x[i]-x[j])*(x[i]-x[j])+(y[i]-y[j])*(y[i]-y[j]);
}
main()
{
	ll n,k,i,j;
	 cin>>n>>k;
	 if(k>(n*(n-1)))
	 	cout<<"no solution\n";
	 else
	 {
	 	ll p=1;
	 	ll y1=-1000000000;
	 	ll d=2000000000/n;
	 	for(i=0;i<n;i++)
	 		{
	 			x[i]=i;y[i]=y1;
	 			y1=y1+d;
	 		}
	 	ll tot=0;
	 	d=INT_MAX;
	 	for(i=0;i<n;i++)
	 	{
	 		for(j=i+1;j<n;j++)
	 		{
	 			tot++;
	 			if(x[j]-x[i]>=sqrt(d))
	 				break;
	 			d=min(d,dist(i,j));
	 		}
	 	}
	 	if(tot<=k)
	 		cout<<"no solution\n";
	 	else
	 	{
	 		for(i=0;i<n;i++)
	 			cout<<x[i]<<" "<<y[i]<<"\n";
	 	}
	 }
}


#include<bits/stdc++.h>
#define ll long long
using namespace std;
main()
{
	ll n,k,i;
	 cin>>n>>k;
	 if(k>(n*(n-1)))
	 	cout<<"no solution\n";
	 else
	 {
	 	ll p=1;
	 	ll y=-1000000000;
	 	ll d=2000000000/n;
	 	for(i=0;i<n;i++)
	 		{
	 			cout<<i<<" "<<y<<"\n";
	 			y=y+d;
	 		}
	 }
}


#include<bits/stdc++.h>
#define ll long long
using namespace std;
main()
{
	ll n,k,i;
	 cin>>n>>k;
	 if(k>(n*(n-1)))
	 	cout<<"no solution\n";
	 else
	 {
	 	ll p=1;
	 	for(i=0;i<n;i++)
	 		{
	 			if(p==1)
	 			cout<<i<<" "<<1000000000<<"\n";
	 			else
	 				cout<<i<<" "<<0<<"\n";
	 			p=p*-1;
	 		}
	 }
}


#include<bits/stdc++.h>
#define ll long long
using namespace std;
main()
{
	ll n,k,i;
	 cin>>n>>k;
	 if(k>(n*(n-1)))
	 	cout<<"no solution\n";
	 else
	 {
	 	for(i=0;i<n;i++)
	 		cout<<i<<" "<<1000000000<<"\n";
	 }
}


#include <bits/stdc++.h>
using namespace std;
#define rep(i,a,b) for(int i=a;i<b;i++)
#define pb push_back
#define mp make_pair
#define rlp(i,a,b) for(int i=a;i>b;i--)
#define ft first
#define sd second
#define pii pair<int,int>
#define all(vect) sort(vect.begin(),vect.end())
#define rall(vect) sort(vect.rbegin(),rend())
const int num = 200001;
typedef long long ll;
int main()
{
	int n,k;
	cin >> n >> k;
	int cur = ((n)*(n-1))/2;
	if(cur<k)
	{
		cout << "no solution\n";
	}
	else
	{
		int ft = 1;
		int sd = 1;
		cout << ft << " " << sd << "\n";
		cout << ft+10 << " " << sd << "\n";
		ft+=10;
		sd+=11;
		rep(i,2,n)
		{
			cout << ft << " " << sd << "\n";
			sd+=11;
		}

	}

	return 0;
}


#include <bits/stdc++.h>
using namespace std;
#define rep(i,a,b) for(int i=a;i<b;i++)
#define pb push_back
#define mp make_pair
#define rlp(i,a,b) for(int i=a;i>b;i--)
#define ft first
#define sd second
#define pii pair<int,int>
#define all(vect) sort(vect.begin(),vect.end())
#define rall(vect) sort(vect.rbegin(),rend())
const int num = 200001;
typedef long long ll;
vector <pair <ll,ll> > vect;
ll dist(pair <ll,ll> a,pair<ll,ll> b)
{
	return sqrt((a.ft-b.ft)*(a.ft-b.ft)+(a.sd-b.sd)*(a.sd-b.sd));
}
int main()
{
	ll n,k;
	cin >> n >> k;
	ll cur = ((n)*(n-1))/2;
	if(cur<=k)
	{
		cout << "no solution\n";
	}
	else
	{
		ll ft = 1;
		ll sd = 1;
		vect.pb(mp(1,1));
		vect.pb(mp(11,1));
		cout << ft << " " << sd << "\n";
		cout << ft+10 << " " << sd << "\n";
		ft=10;
		sd+=11;
		rep(i,2,n)
		{
			vect.pb(mp(ft,sd));
			cout << ft << " " << sd << "\n";
			sd+=11;
		}
	}
	// ll tot = 0;
	// ll d = LONG_MAX;
	// rep(i,0,n)
	// {
	// 	rep(j,i+1,n)
	// 	{
	// 		++tot;
	// 		if((vect[j].ft-vect[i].ft)>=d)
	// 			break;
	// 		d = min(d,dist(vect[j],vect[i]));
	// 	}
	// }
	// cout << tot << "\n";

	return 0;
}


#include <bits/stdc++.h>
using namespace std;
#define rep(i,a,b) for(int i=a;i<b;i++)
#define pb push_back
#define mp make_pair
#define rlp(i,a,b) for(int i=a;i>b;i--)
#define ft first
#define sd second
#define pii pair<int,int>
#define all(vect) sort(vect.begin(),vect.end())
#define rall(vect) sort(vect.rbegin(),rend())
const int num = 200001;
typedef long long ll;
vector <pair <ll,ll> > vect;
ll dist(pair <ll,ll> a,pair<ll,ll> b)
{
	return sqrt((a.ft-b.ft)*(a.ft-b.ft)+(a.sd-b.sd)*(a.sd-b.sd));
}
int main()
{
	ll n,k;
	cin >> n >> k;
	ll cur = ((n)*(n-1))/2;
	if(cur<=k)
	{
		cout << "no solution\n";
	}
	else
	{
		ll ft = 1;
		ll sd = 1;
		vect.pb(mp(1,1));
		vect.pb(mp(11,1));
		cout << ft << " " << sd << "\n";
		cout << ft+10 << " " << sd << "\n";
		ft+=10;
		sd+=11;
		rep(i,2,n)
		{
			vect.pb(mp(ft,sd));
			cout << ft << " " << sd << "\n";
			sd+=11;
		}
	}
	// ll tot = 0;
	// ll d = LONG_MAX;
	// rep(i,0,n)
	// {
	// 	rep(j,i+1,n)
	// 	{
	// 		++tot;
	// 		if((vect[j].ft-vect[j].ft)>=d)
	// 			break;
	// 		d = min(d,dist(vect[j],vect[i]));
	// 	}
	// }
	// cout << tot << "\n";

	return 0;
}


#include <bits/stdc++.h>
using namespace std;
#define rep(i,a,b) for(int i=a;i<b;i++)
#define pb push_back
#define mp make_pair
#define rlp(i,a,b) for(int i=a;i>b;i--)
#define ft first
#define sd second
#define pii pair<int,int>
#define all(vect) sort(vect.begin(),vect.end())
#define rall(vect) sort(vect.rbegin(),rend())
const int num = 200001;
typedef long long ll;
int main()
{
	int n,k;
	cin >> n >> k;
	int cur = ((n)*(n-1))/2;
	if(cur<=k)
	{
		cout << "no solution\n";
	}
	else
	{
		int ft = 1;
		int sd = 1;
		cout << ft << " " << sd << "\n";
		cout << ft+10 << " " << sd << "\n";
		ft+=10;
		sd+=11;
		rep(i,2,n)
		{
			cout << ft << " " << sd << "\n";
			sd+=11;
		}

	}

	return 0;
}


#include<bits/stdc++.h>
using namespace std;
//      std macros
typedef long long ll;
typedef vector<list<ll> > vli;
typedef vector<ll > vi;
typedef vector<pair<ll,ll> > vpll;
typedef vector<pair<int,int> > vpii;
typedef pair<int ,int> pii;
//      dereference
#define F first
#define S second
#define pb push_back
#define mp make_pair
#define in insert
#define pu push
#define fr front
//      loops
#define rep(i,n) for(int i=0;i<n;++i)
#define REP(i,a,b) for(int i=a;i<=b;++i)
#define PER(i,b,a) for(int i=b;i>=a;--i)
#define all(X) (X).begin(), (X).end()
//      I/O
#define sd2(x,y) scanf("%d%d",&x,&y)
#define sd3(x,y,z) scanf("%d%d%d",&x,&y,&z)
#define sll2(x,y) scanf("%lld%lld",&x,&y)
#define sll3(x,y,z) scanf("%lld%lld%lld",&x,&y,&z)
#define sd(n) scanf("%d",&n)
#define sll(n) scanf("%lld",&n)
#define sc(n) scanf("%c",&n)
#define ss(n) scanf("%s",n)
#define oll(n) printf("%lld\n",n)
//      debug
#define debug(x) cout<<"debug->"<<#x<<"::"<<x<<endl
#define debug2(x,y) cout<<#x<<" :: "<<x<<"\t"<<#y<<" :: "<<y<<"\n"
#define debug3(x,y,z) cout<<#x<<" :: "<<x<<"\t"<<#y<<" :: "<<y<<"\t"<<#z<<" :: "<<z<<"\n"
//      set values
#define mset(n,k) memset(n,k,sizeof(n))
#define MOD 1000000007
ll INV2=500000004;
ll INV6=166666668;
//modular expo
ll power(ll a,ll b, ll c){
    ll x=1,y=a;
    while(b>0){
        if(b&1)
            x=(x*y)%c;
        y=(y*y)%c;
        b/=2;
    }
    return x%c;
}
//perfect numbers till 10^6 6, 28, 496, 8128
int dx[]={0,-1,0,1};
int dy[]={-1,0,1,0};//clockwise from left
int dr[]={1,1,0,-1,-1,-1, 0, 1};
int dc[]={0,1,1, 1, 0,-1,-1,-1};//anticlockwise from down
int main(){

 	int n,k;
 	sd2(n,k);
 	int tot=n;
 	if(tot<=k)
 	{
 		printf("no solution\n");
 	}
 	else
 	{
 		REP(i,1,n)
 		{
 			printf("%d 0\n",i);
 		}
 	}

return 0;
}


#include<bits/stdc++.h>
using namespace std;
//      std macros
typedef long long ll;
typedef vector<list<ll> > vli;
typedef vector<ll > vi;
typedef vector<pair<ll,ll> > vpll;
typedef vector<pair<int,int> > vpii;
typedef pair<int ,int> pii;
//      dereference
#define F first
#define S second
#define pb push_back
#define mp make_pair
#define in insert
#define pu push
#define fr front
//      loops
#define rep(i,n) for(int i=0;i<n;++i)
#define REP(i,a,b) for(int i=a;i<=b;++i)
#define PER(i,b,a) for(int i=b;i>=a;--i)
#define all(X) (X).begin(), (X).end()
//      I/O
#define sd2(x,y) scanf("%d%d",&x,&y)
#define sd3(x,y,z) scanf("%d%d%d",&x,&y,&z)
#define sll2(x,y) scanf("%lld%lld",&x,&y)
#define sll3(x,y,z) scanf("%lld%lld%lld",&x,&y,&z)
#define sd(n) scanf("%d",&n)
#define sll(n) scanf("%lld",&n)
#define sc(n) scanf("%c",&n)
#define ss(n) scanf("%s",n)
#define oll(n) printf("%lld\n",n)
//      debug
#define debug(x) cout<<"debug->"<<#x<<"::"<<x<<endl
#define debug2(x,y) cout<<#x<<" :: "<<x<<"\t"<<#y<<" :: "<<y<<"\n"
#define debug3(x,y,z) cout<<#x<<" :: "<<x<<"\t"<<#y<<" :: "<<y<<"\t"<<#z<<" :: "<<z<<"\n"
//      set values
#define mset(n,k) memset(n,k,sizeof(n))
#define MOD 1000000007
ll INV2=500000004;
ll INV6=166666668;
//modular expo
ll power(ll a,ll b, ll c){
    ll x=1,y=a;
    while(b>0){
        if(b&1)
            x=(x*y)%c;
        y=(y*y)%c;
        b/=2;
    }
    return x%c;
}
//perfect numbers till 10^6 6, 28, 496, 8128
int dx[]={0,-1,0,1};
int dy[]={-1,0,1,0};//clockwise from left
int dr[]={1,1,0,-1,-1,-1, 0, 1};
int dc[]={0,1,1, 1, 0,-1,-1,-1};//anticlockwise from down
int main(){

 	int n,k;
 	sd2(n,k);
 	int tot=n+1;
 	if(tot<=k)
 	{
 		printf("no solution\n");
 	}
 	else
 	{
 		REP(i,1,n)
 		{
 			printf("%d 0\n",i);
 		}
 	}

return 0;
}


#include<bits/stdc++.h>
using namespace std;
//      std macros
typedef long long ll;
typedef vector<list<ll> > vli;
typedef vector<ll > vi;
typedef vector<pair<ll,ll> > vpll;
typedef vector<pair<int,int> > vpii;
typedef pair<int ,int> pii;
//      dereference
#define F first
#define S second
#define pb push_back
#define mp make_pair
#define in insert
#define pu push
#define fr front
//      loops
#define rep(i,n) for(int i=0;i<n;++i)
#define REP(i,a,b) for(int i=a;i<=b;++i)
#define PER(i,b,a) for(int i=b;i>=a;--i)
#define all(X) (X).begin(), (X).end()
//      I/O
#define sd2(x,y) scanf("%d%d",&x,&y)
#define sd3(x,y,z) scanf("%d%d%d",&x,&y,&z)
#define sll2(x,y) scanf("%lld%lld",&x,&y)
#define sll3(x,y,z) scanf("%lld%lld%lld",&x,&y,&z)
#define sd(n) scanf("%d",&n)
#define sll(n) scanf("%lld",&n)
#define sc(n) scanf("%c",&n)
#define ss(n) scanf("%s",n)
#define oll(n) printf("%lld\n",n)
//      debug
#define debug(x) cout<<"debug->"<<#x<<"::"<<x<<endl
#define debug2(x,y) cout<<#x<<" :: "<<x<<"\t"<<#y<<" :: "<<y<<"\n"
#define debug3(x,y,z) cout<<#x<<" :: "<<x<<"\t"<<#y<<" :: "<<y<<"\t"<<#z<<" :: "<<z<<"\n"
//      set values
#define mset(n,k) memset(n,k,sizeof(n))
#define MOD 1000000007
ll INV2=500000004;
ll INV6=166666668;
//modular expo
ll power(ll a,ll b, ll c){
    ll x=1,y=a;
    while(b>0){
        if(b&1)
            x=(x*y)%c;
        y=(y*y)%c;
        b/=2;
    }
    return x%c;
}
//perfect numbers till 10^6 6, 28, 496, 8128
int dx[]={0,-1,0,1};
int dy[]={-1,0,1,0};//clockwise from left
int dr[]={1,1,0,-1,-1,-1, 0, 1};
int dc[]={0,1,1, 1, 0,-1,-1,-1};//anticlockwise from down
int main(){

 	int n,k;
 	sd2(n,k);
 	int tot=2*n-3;
 	if(tot<=k)
 	{
 		printf("no solution\n");
 	}
 	else
 	{
 		REP(i,1,n)
 		{
 			printf("0 %d\n",i);
 		}
 	}

return 0;
}


#include<bits/stdc++.h>
using namespace std;
//      std macros
typedef long long ll;
typedef vector<list<ll> > vli;
typedef vector<ll > vi;
typedef vector<pair<ll,ll> > vpll;
typedef vector<pair<int,int> > vpii;
typedef pair<int ,int> pii;
//      dereference
#define F first
#define S second
#define pb push_back
#define mp make_pair
#define in insert
#define pu push
#define fr front
//      loops
#define rep(i,n) for(int i=0;i<n;++i)
#define REP(i,a,b) for(int i=a;i<=b;++i)
#define PER(i,b,a) for(int i=b;i>=a;--i)
#define all(X) (X).begin(), (X).end()
//      I/O
#define sd2(x,y) scanf("%d%d",&x,&y)
#define sd3(x,y,z) scanf("%d%d%d",&x,&y,&z)
#define sll2(x,y) scanf("%lld%lld",&x,&y)
#define sll3(x,y,z) scanf("%lld%lld%lld",&x,&y,&z)
#define sd(n) scanf("%d",&n)
#define sll(n) scanf("%lld",&n)
#define sc(n) scanf("%c",&n)
#define ss(n) scanf("%s",n)
#define oll(n) printf("%lld\n",n)
//      debug
#define debug(x) cout<<"debug->"<<#x<<"::"<<x<<endl
#define debug2(x,y) cout<<#x<<" :: "<<x<<"\t"<<#y<<" :: "<<y<<"\n"
#define debug3(x,y,z) cout<<#x<<" :: "<<x<<"\t"<<#y<<" :: "<<y<<"\t"<<#z<<" :: "<<z<<"\n"
//      set values
#define mset(n,k) memset(n,k,sizeof(n))
#define MOD 1000000007
ll INV2=500000004;
ll INV6=166666668;
//modular expo
ll power(ll a,ll b, ll c){
    ll x=1,y=a;
    while(b>0){
        if(b&1)
            x=(x*y)%c;
        y=(y*y)%c;
        b/=2;
    }
    return x%c;
}
//perfect numbers till 10^6 6, 28, 496, 8128
int dx[]={0,-1,0,1};
int dy[]={-1,0,1,0};//clockwise from left
int dr[]={1,1,0,-1,-1,-1, 0, 1};
int dc[]={0,1,1, 1, 0,-1,-1,-1};//anticlockwise from down
int main(){

 	int n,k;
 	sd2(n,k);
 	int tot=2*n-3;
 	if(tot<=k)
 	{
 		printf("no solution\n");
 	}
 	else
 	{
 		REP(i,1,n)
 		{
 			printf("%d 0\n",i);
 		}
 	}

return 0;
}


#include<bits/stdc++.h>
using namespace std;
//      std macros
typedef long long ll;
typedef vector<list<ll> > vli;
typedef vector<ll > vi;
typedef vector<pair<ll,ll> > vpll;
typedef vector<pair<int,int> > vpii;
typedef pair<int ,int> pii;
//      dereference
#define F first
#define S second
#define pb push_back
#define mp make_pair
#define in insert
#define pu push
#define fr front
//      loops
#define rep(i,n) for(int i=0;i<n;++i)
#define REP(i,a,b) for(int i=a;i<=b;++i)
#define PER(i,b,a) for(int i=b;i>=a;--i)
#define all(X) (X).begin(), (X).end()
//      I/O
#define sd2(x,y) scanf("%d%d",&x,&y)
#define sd3(x,y,z) scanf("%d%d%d",&x,&y,&z)
#define sll2(x,y) scanf("%lld%lld",&x,&y)
#define sll3(x,y,z) scanf("%lld%lld%lld",&x,&y,&z)
#define sd(n) scanf("%d",&n)
#define sll(n) scanf("%lld",&n)
#define sc(n) scanf("%c",&n)
#define ss(n) scanf("%s",n)
#define oll(n) printf("%lld\n",n)
//      debug
#define debug(x) cout<<"debug->"<<#x<<"::"<<x<<endl
#define debug2(x,y) cout<<#x<<" :: "<<x<<"\t"<<#y<<" :: "<<y<<"\n"
#define debug3(x,y,z) cout<<#x<<" :: "<<x<<"\t"<<#y<<" :: "<<y<<"\t"<<#z<<" :: "<<z<<"\n"
//      set values
#define mset(n,k) memset(n,k,sizeof(n))
#define MOD 1000000007
ll INV2=500000004;
ll INV6=166666668;
//modular expo
ll power(ll a,ll b, ll c){
    ll x=1,y=a;
    while(b>0){
        if(b&1)
            x=(x*y)%c;
        y=(y*y)%c;
        b/=2;
    }
    return x%c;
}
//perfect numbers till 10^6 6, 28, 496, 8128
int dx[]={0,-1,0,1};
int dy[]={-1,0,1,0};//clockwise from left
int dr[]={1,1,0,-1,-1,-1, 0, 1};
int dc[]={0,1,1, 1, 0,-1,-1,-1};//anticlockwise from down
int main(){

 	int n,k;
 	sd2(n,k);
 	int tot=(n*(n-1))/2;
 	if(tot<=k)
 	{
 		printf("no solution\n");
 	}
 	else
 	{
 		REP(i,1,n)
 		{
 			printf("0 %d\n",i);
 		}
 	}

return 0;
}


#include<iostream>
#include<stdio.h>
using namespace std;
int main()
{
    long long i, n, k;
    scanf("%lld%lld",&n,&k);
    if((n*(n-1)/2)<k)
    {
        printf("no solution\n");
        return 0;
    }
    for(i=0;i<n;i++)
        {
            printf("%lld %lld\n",i/2, i);
        }
        return 0;
}


#include<iostream>
#include<stdio.h>
using namespace std;
int main()
{
    long long i, n, k;
    scanf("%lld%lld",&n,&k);
    if((n*(n-1)/2)<k)
    {
        printf("no solution\n");
        return 0;
    }
    for(i=0;i<n;i++)
        {
            printf("%lld 0\n",(i+1)/2);
        }
        return 0;
}


#include<iostream>
#include<stdio.h>
using namespace std;
int main()
{
    long long i, n, k;
    scanf("%lld%lld",&n,&k);
    if((n*(n-1)/2)<k)
    {
        printf("no solution\n");
        return 0;
    }
    for(i=0;i<n;i++)
        {
            printf("%lld 0\n",i/2);
        }
        return 0;
}


#include<iostream>
#include<stdio.h>
using namespace std;
int main()
{
    long long i, n, k;
    scanf("%lld%lld",&n,&k);
    if((n*(n-1)/2)<=k)
    {
        printf("no solution\n");
        return 0;
    }
    for(i=1;i<=n;i++)
        {
            printf("0 %lld\n", i);
        }
        return 0;
}


#include<iostream>
#include<stdio.h>
using namespace std;
int main()
{
    long long i, n, k;
    scanf("%lld%lld",&n,&k);
    if((n*(n-1)/2)<k)
    {
        printf("no solution\n");
        return 0;
    }
    for(i=0;i<n;i++)
        {
            printf("0 %lld\n",i);
        }
        return 0;
}


/****** BISMILLAH HIR RAHMANIR RAHIM ******/

#include <bits/stdc++.h>
// #include <ext/pb_ds/assoc_container.hpp>
// #include <ext/pb_ds/tree_policy.hpp>
// #include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
// using namespace __gnu_pbds;
// using namespace __gnu_cxx;

typedef long long ll;
typedef unsigned int ul;
typedef unsigned long long ull;
typedef vector <int> vi;
typedef map<string,string> mss;
typedef map<int, vector<int> > mvii;
typedef map<int, int> mii;
typedef queue <int> qi;
typedef map <int, vector<string> > mvis;
typedef map <string, vector<int> > mvsi;
typedef vector <string> vs;
typedef pair <int, int> pii;
typedef vector<pair<int,int> > vpii;

// Order Statistic Tree

/* Special functions:

		find_by_order(k) --> returns iterator to the kth largest element counting from 0
		order_of_key(val) --> returns the number of items in a set that are strictly smaller than our item
*/

// typedef tree<
// int,
// null_type,
// less<int>,
// rb_tree_tag,
// tree_order_statistics_node_update>
// ordered_set;

#define MP make_pair
#define SORT(a) sort (a.begin(), a.end())
#define REVERSE(a) reverse (a.begin(), a.end())
#define ALL(a) a.begin(), a.end()
#define PI acos(-1)
#define ms(x,y) memset (x, y, sizeof (x))
#define INF 2000000000
#define pb push_back
#define MAX 100002
#define debug cout<<"A"<<"\n"
#define prnt(a) cout<<a<<"\n"
#define mod 1000000007LL
#define FOR(i,a,b) for (int i=(a); i<(b); i++)
#define FORr(i,a,b) for (int i=(a); i>=b; i--)
#define itrALL(c,itr) for(__typeof((c).begin()) itr=(c).begin();itr!=(c).end();itr++)
#define lc ((node)<<1)
#define rc ((node)<<1|1)
#define VecPrnt(v) FOR(J,0,v.size()) cout<<v[J]<<" "; cout<<endl
#define endl "\n"
#define PrintPair(x) cout<<x.first<<" "<<x.second<<endl
#define ClearQ(x); while(!x.empty()) x.pop()
#define EPS 1e-9
#define ArrPrint(a,st,en) for(int J=st; J<=en; J++) cout<<a[J]<<" "; cout<<endl;

/* Direction Array */

// int fx[]={1,-1,0,0};
// int fy[]={0,0,1,-1};
// int fx[]={0,0,1,-1,-1,1,-1,1};
// int fy[]={-1,1,0,0,1,1,-1,-1};

template <class T> inline T bigmod(T p,T e,T M)
{
    ll ret = 1;
    for(; e > 0; e >>= 1)
    {
        if(e & 1) ret = (ret * p) % M;
        p = (p * p) % M;
    } return (T)ret;
}

template <class T> inline T gcd(T a,T b){if(b==0)return a;return gcd(b,a%b);}
template <class T> inline T modinverse(T a,T M){return bigmod(a,M-2,M);}
template <class T> inline T lcm(T a,T b) {a=abs(a);b=abs(b); return (a/gcd(a,b))*b;}
template <class T, class X> inline bool getbit(T a, X i) { T t=1; return ((a&(t<<i))>0);}
template <class T, class X> inline T setbit(T a, X i) { T t=1;return (a|(t<<i)); }
template <class T, class X> inline T resetbit(T a, X i) { T t=1;return (a&(~(t<<i)));}

inline ll getnum()
{
    char c = getchar();
    ll num,sign=1;
    for(;c<'0'||c>'9';c=getchar())if(c=='-')sign=-1;
    for(num=0;c>='0'&&c<='9';)
    {
        c-='0';
        num = num*10+c;
        c=getchar();
    }
    return num*sign;
}

inline ll power(ll a, ll b)
{
	ll multiply=1;
	FOR(i,0,b)
	{
		multiply*=a;
	}
	return multiply;
}

/****** END OF HEADER ******/

int n, k;
vpii all;

void Test()
{
	int tot=0, d=INF;

	FOR(i,0,all.size())
	{
		cout<<"For point: "<<i<<endl;
		FOR(j,i+1,all.size())
		{
			++tot;
			cout<<"tot: "<<tot<<endl;
			if(all[j].first-all[i].first>=d) break;
			d=min(d,all[j].first-all[i].first);
		}
	}

	cout<<"tot: "<<tot<<endl;
}

int main()
{
    // ios_base::sync_with_stdio(0);
    // cin.tie(NULL); cout.tie(NULL);
    // freopen("in.txt","r",stdin);

    int test, cases=1;

    cin>>n>>k;

    if(k>2*n-3) prnt("no solution");
    else
    {
    	int x=0, y=0, delta=2000;
    	for(int i=1; i<=n; i++)
    	{
    		cout<<x<<" "<<y<<endl;
    		all.pb({x,y});
    		x+=delta;
    		delta--;
    	}
    	// Test();
    }

    return 0;
}


/****** BISMILLAH HIR RAHMANIR RAHIM ******/

#include <bits/stdc++.h>
// #include <ext/pb_ds/assoc_container.hpp>
// #include <ext/pb_ds/tree_policy.hpp>
// #include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
// using namespace __gnu_pbds;
// using namespace __gnu_cxx;

typedef long long ll;
typedef unsigned int ul;
typedef unsigned long long ull;
typedef vector <int> vi;
typedef map<string,string> mss;
typedef map<int, vector<int> > mvii;
typedef map<int, int> mii;
typedef queue <int> qi;
typedef map <int, vector<string> > mvis;
typedef map <string, vector<int> > mvsi;
typedef vector <string> vs;
typedef pair <int, int> pii;
typedef vector<pair<int,int> > vpii;

// Order Statistic Tree

/* Special functions:

		find_by_order(k) --> returns iterator to the kth largest element counting from 0
		order_of_key(val) --> returns the number of items in a set that are strictly smaller than our item
*/

// typedef tree<
// int,
// null_type,
// less<int>,
// rb_tree_tag,
// tree_order_statistics_node_update>
// ordered_set;

#define MP make_pair
#define SORT(a) sort (a.begin(), a.end())
#define REVERSE(a) reverse (a.begin(), a.end())
#define ALL(a) a.begin(), a.end()
#define PI acos(-1)
#define ms(x,y) memset (x, y, sizeof (x))
#define INF 2000000000
#define pb push_back
#define MAX 100002
#define debug cout<<"A"<<"\n"
#define prnt(a) cout<<a<<"\n"
#define mod 1000000007LL
#define FOR(i,a,b) for (int i=(a); i<(b); i++)
#define FORr(i,a,b) for (int i=(a); i>=b; i--)
#define itrALL(c,itr) for(__typeof((c).begin()) itr=(c).begin();itr!=(c).end();itr++)
#define lc ((node)<<1)
#define rc ((node)<<1|1)
#define VecPrnt(v) FOR(J,0,v.size()) cout<<v[J]<<" "; cout<<endl
#define endl "\n"
#define PrintPair(x) cout<<x.first<<" "<<x.second<<endl
#define ClearQ(x); while(!x.empty()) x.pop()
#define EPS 1e-9
#define ArrPrint(a,st,en) for(int J=st; J<=en; J++) cout<<a[J]<<" "; cout<<endl;

/* Direction Array */

// int fx[]={1,-1,0,0};
// int fy[]={0,0,1,-1};
// int fx[]={0,0,1,-1,-1,1,-1,1};
// int fy[]={-1,1,0,0,1,1,-1,-1};

template <class T> inline T bigmod(T p,T e,T M)
{
    ll ret = 1;
    for(; e > 0; e >>= 1)
    {
        if(e & 1) ret = (ret * p) % M;
        p = (p * p) % M;
    } return (T)ret;
}

template <class T> inline T gcd(T a,T b){if(b==0)return a;return gcd(b,a%b);}
template <class T> inline T modinverse(T a,T M){return bigmod(a,M-2,M);}
template <class T> inline T lcm(T a,T b) {a=abs(a);b=abs(b); return (a/gcd(a,b))*b;}
template <class T, class X> inline bool getbit(T a, X i) { T t=1; return ((a&(t<<i))>0);}
template <class T, class X> inline T setbit(T a, X i) { T t=1;return (a|(t<<i)); }
template <class T, class X> inline T resetbit(T a, X i) { T t=1;return (a&(~(t<<i)));}

inline ll getnum()
{
    char c = getchar();
    ll num,sign=1;
    for(;c<'0'||c>'9';c=getchar())if(c=='-')sign=-1;
    for(num=0;c>='0'&&c<='9';)
    {
        c-='0';
        num = num*10+c;
        c=getchar();
    }
    return num*sign;
}

inline ll power(ll a, ll b)
{
	ll multiply=1;
	FOR(i,0,b)
	{
		multiply*=a;
	}
	return multiply;
}

/****** END OF HEADER ******/

int n, k;

int main()
{
    // ios_base::sync_with_stdio(0);
    // cin.tie(NULL); cout.tie(NULL);
    // freopen("in.txt","r",stdin);

    int test, cases=1;

    cin>>n>>k;

    ll t=(ll)n*(n-1);
    t/=2;

    if(k>t) prnt("no solution");
    else
    {
    	int x=0, y=0, delta=2000;
    	for(int i=1; i<=n; i++)
    	{
    		cout<<x<<" "<<y<<endl;
    		x+=delta;
    		delta--;
    	}
    }

    return 0;
}


/****** BISMILLAH HIR RAHMANIR RAHIM ******/

#include <bits/stdc++.h>
// #include <ext/pb_ds/assoc_container.hpp>
// #include <ext/pb_ds/tree_policy.hpp>
// #include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
// using namespace __gnu_pbds;
// using namespace __gnu_cxx;

typedef long long ll;
typedef unsigned int ul;
typedef unsigned long long ull;
typedef vector <int> vi;
typedef map<string,string> mss;
typedef map<int, vector<int> > mvii;
typedef map<int, int> mii;
typedef queue <int> qi;
typedef map <int, vector<string> > mvis;
typedef map <string, vector<int> > mvsi;
typedef vector <string> vs;
typedef pair <int, int> pii;
typedef vector<pair<int,int> > vpii;

// Order Statistic Tree

/* Special functions:

		find_by_order(k) --> returns iterator to the kth largest element counting from 0
		order_of_key(val) --> returns the number of items in a set that are strictly smaller than our item
*/

// typedef tree<
// int,
// null_type,
// less<int>,
// rb_tree_tag,
// tree_order_statistics_node_update>
// ordered_set;

#define MP make_pair
#define SORT(a) sort (a.begin(), a.end())
#define REVERSE(a) reverse (a.begin(), a.end())
#define ALL(a) a.begin(), a.end()
#define PI acos(-1)
#define ms(x,y) memset (x, y, sizeof (x))
#define INF 2000000000
#define pb push_back
#define MAX 100002
#define debug cout<<"A"<<"\n"
#define prnt(a) cout<<a<<"\n"
#define mod 1000000007LL
#define FOR(i,a,b) for (int i=(a); i<(b); i++)
#define FORr(i,a,b) for (int i=(a); i>=b; i--)
#define itrALL(c,itr) for(__typeof((c).begin()) itr=(c).begin();itr!=(c).end();itr++)
#define lc ((node)<<1)
#define rc ((node)<<1|1)
#define VecPrnt(v) FOR(J,0,v.size()) cout<<v[J]<<" "; cout<<endl
#define endl "\n"
#define PrintPair(x) cout<<x.first<<" "<<x.second<<endl
#define ClearQ(x); while(!x.empty()) x.pop()
#define EPS 1e-9
#define ArrPrint(a,st,en) for(int J=st; J<=en; J++) cout<<a[J]<<" "; cout<<endl;

/* Direction Array */

// int fx[]={1,-1,0,0};
// int fy[]={0,0,1,-1};
// int fx[]={0,0,1,-1,-1,1,-1,1};
// int fy[]={-1,1,0,0,1,1,-1,-1};

template <class T> inline T bigmod(T p,T e,T M)
{
    ll ret = 1;
    for(; e > 0; e >>= 1)
    {
        if(e & 1) ret = (ret * p) % M;
        p = (p * p) % M;
    } return (T)ret;
}

template <class T> inline T gcd(T a,T b){if(b==0)return a;return gcd(b,a%b);}
template <class T> inline T modinverse(T a,T M){return bigmod(a,M-2,M);}
template <class T> inline T lcm(T a,T b) {a=abs(a);b=abs(b); return (a/gcd(a,b))*b;}
template <class T, class X> inline bool getbit(T a, X i) { T t=1; return ((a&(t<<i))>0);}
template <class T, class X> inline T setbit(T a, X i) { T t=1;return (a|(t<<i)); }
template <class T, class X> inline T resetbit(T a, X i) { T t=1;return (a&(~(t<<i)));}

inline ll getnum()
{
    char c = getchar();
    ll num,sign=1;
    for(;c<'0'||c>'9';c=getchar())if(c=='-')sign=-1;
    for(num=0;c>='0'&&c<='9';)
    {
        c-='0';
        num = num*10+c;
        c=getchar();
    }
    return num*sign;
}

inline ll power(ll a, ll b)
{
	ll multiply=1;
	FOR(i,0,b)
	{
		multiply*=a;
	}
	return multiply;
}

/****** END OF HEADER ******/

int n, k;
vpii all;

void Test()
{
	int tot=0, d=INF;

	FOR(i,0,all.size())
	{
		cout<<"For point: "<<i<<endl;
		FOR(j,i+1,all.size())
		{
			++tot;
			cout<<"tot: "<<tot<<endl;
			if(all[j].first-all[i].first>=d) break;
			d=min(d,all[j].second-all[i].second);
		}
	}

	cout<<"tot: "<<tot<<endl;
}

int main()
{
    // ios_base::sync_with_stdio(0);
    // cin.tie(NULL); cout.tie(NULL);
    // freopen("in.txt","r",stdin);

    int test, cases=1;

    cin>>n>>k;

    if(k>=((ll)n*(n-1))/2) prnt("no solution");
    else
    {
    	int x=0, y=0, delta=2000;
    	for(int i=1; i<=n; i++)
    	{
    		cout<<x<<" "<<y<<endl;
    		all.pb({x,y});
    		y+=delta;
    		delta--;
    	}
    	Test();
    }

    return 0;
}


/****** BISMILLAH HIR RAHMANIR RAHIM ******/

#include <bits/stdc++.h>
// #include <ext/pb_ds/assoc_container.hpp>
// #include <ext/pb_ds/tree_policy.hpp>
// #include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
// using namespace __gnu_pbds;
// using namespace __gnu_cxx;

typedef long long ll;
typedef unsigned int ul;
typedef unsigned long long ull;
typedef vector <int> vi;
typedef map<string,string> mss;
typedef map<int, vector<int> > mvii;
typedef map<int, int> mii;
typedef queue <int> qi;
typedef map <int, vector<string> > mvis;
typedef map <string, vector<int> > mvsi;
typedef vector <string> vs;
typedef pair <int, int> pii;
typedef vector<pair<int,int> > vpii;

// Order Statistic Tree

/* Special functions:

		find_by_order(k) --> returns iterator to the kth largest element counting from 0
		order_of_key(val) --> returns the number of items in a set that are strictly smaller than our item
*/

// typedef tree<
// int,
// null_type,
// less<int>,
// rb_tree_tag,
// tree_order_statistics_node_update>
// ordered_set;

#define MP make_pair
#define SORT(a) sort (a.begin(), a.end())
#define REVERSE(a) reverse (a.begin(), a.end())
#define ALL(a) a.begin(), a.end()
#define PI acos(-1)
#define ms(x,y) memset (x, y, sizeof (x))
#define INF 2000000000
#define pb push_back
#define MAX 100002
#define debug cout<<"A"<<"\n"
#define prnt(a) cout<<a<<"\n"
#define mod 1000000007LL
#define FOR(i,a,b) for (int i=(a); i<(b); i++)
#define FORr(i,a,b) for (int i=(a); i>=b; i--)
#define itrALL(c,itr) for(__typeof((c).begin()) itr=(c).begin();itr!=(c).end();itr++)
#define lc ((node)<<1)
#define rc ((node)<<1|1)
#define VecPrnt(v) FOR(J,0,v.size()) cout<<v[J]<<" "; cout<<endl
#define endl "\n"
#define PrintPair(x) cout<<x.first<<" "<<x.second<<endl
#define ClearQ(x); while(!x.empty()) x.pop()
#define EPS 1e-9
#define ArrPrint(a,st,en) for(int J=st; J<=en; J++) cout<<a[J]<<" "; cout<<endl;

/* Direction Array */

// int fx[]={1,-1,0,0};
// int fy[]={0,0,1,-1};
// int fx[]={0,0,1,-1,-1,1,-1,1};
// int fy[]={-1,1,0,0,1,1,-1,-1};

template <class T> inline T bigmod(T p,T e,T M)
{
    ll ret = 1;
    for(; e > 0; e >>= 1)
    {
        if(e & 1) ret = (ret * p) % M;
        p = (p * p) % M;
    } return (T)ret;
}

template <class T> inline T gcd(T a,T b){if(b==0)return a;return gcd(b,a%b);}
template <class T> inline T modinverse(T a,T M){return bigmod(a,M-2,M);}
template <class T> inline T lcm(T a,T b) {a=abs(a);b=abs(b); return (a/gcd(a,b))*b;}
template <class T, class X> inline bool getbit(T a, X i) { T t=1; return ((a&(t<<i))>0);}
template <class T, class X> inline T setbit(T a, X i) { T t=1;return (a|(t<<i)); }
template <class T, class X> inline T resetbit(T a, X i) { T t=1;return (a&(~(t<<i)));}

inline ll getnum()
{
    char c = getchar();
    ll num,sign=1;
    for(;c<'0'||c>'9';c=getchar())if(c=='-')sign=-1;
    for(num=0;c>='0'&&c<='9';)
    {
        c-='0';
        num = num*10+c;
        c=getchar();
    }
    return num*sign;
}

inline ll power(ll a, ll b)
{
	ll multiply=1;
	FOR(i,0,b)
	{
		multiply*=a;
	}
	return multiply;
}

/****** END OF HEADER ******/

int n, k;
vpii all;

void Test()
{
	int tot=0, d=INF;

	FOR(i,0,all.size())
	{
		cout<<"For point: "<<i<<endl;
		FOR(j,i+1,all.size())
		{
			++tot;
			cout<<"tot: "<<tot<<endl;
			if(all[j].first-all[i].first>=d) break;
			d=min(d,all[j].second-all[i].second);
		}
	}

	cout<<"tot: "<<tot<<endl;
}

int main()
{
    // ios_base::sync_with_stdio(0);
    // cin.tie(NULL); cout.tie(NULL);
    // freopen("in.txt","r",stdin);

    int test, cases=1;

    cin>>n>>k;

    if(k>=((ll)n*(n-1))/2) prnt("no solution");
    else
    {
    	int x=0, y=0, delta=2000;
    	for(int i=1; i<=n; i++)
    	{
    		cout<<x<<" "<<y<<endl;
    		all.pb({x,y});
    		y+=delta;
    		delta--;
    	}
    	// Test();
    }

    return 0;
}


/****** BISMILLAH HIR RAHMANIR RAHIM ******/

#include <bits/stdc++.h>
// #include <ext/pb_ds/assoc_container.hpp>
// #include <ext/pb_ds/tree_policy.hpp>
// #include <ext/pb_ds/detail/standard_policies.hpp>

using namespace std;
// using namespace __gnu_pbds;
// using namespace __gnu_cxx;

typedef long long ll;
typedef unsigned int ul;
typedef unsigned long long ull;
typedef vector <int> vi;
typedef map<string,string> mss;
typedef map<int, vector<int> > mvii;
typedef map<int, int> mii;
typedef queue <int> qi;
typedef map <int, vector<string> > mvis;
typedef map <string, vector<int> > mvsi;
typedef vector <string> vs;
typedef pair <int, int> pii;
typedef vector<pair<int,int> > vpii;

// Order Statistic Tree

/* Special functions:

		find_by_order(k) --> returns iterator to the kth largest element counting from 0
		order_of_key(val) --> returns the number of items in a set that are strictly smaller than our item
*/

// typedef tree<
// int,
// null_type,
// less<int>,
// rb_tree_tag,
// tree_order_statistics_node_update>
// ordered_set;

#define MP make_pair
#define SORT(a) sort (a.begin(), a.end())
#define REVERSE(a) reverse (a.begin(), a.end())
#define ALL(a) a.begin(), a.end()
#define PI acos(-1)
#define ms(x,y) memset (x, y, sizeof (x))
#define INF 2000000000
#define pb push_back
#define MAX 100002
#define debug cout<<"A"<<"\n"
#define prnt(a) cout<<a<<"\n"
#define mod 1000000007LL
#define FOR(i,a,b) for (int i=(a); i<(b); i++)
#define FORr(i,a,b) for (int i=(a); i>=b; i--)
#define itrALL(c,itr) for(__typeof((c).begin()) itr=(c).begin();itr!=(c).end();itr++)
#define lc ((node)<<1)
#define rc ((node)<<1|1)
#define VecPrnt(v) FOR(J,0,v.size()) cout<<v[J]<<" "; cout<<endl
#define endl "\n"
#define PrintPair(x) cout<<x.first<<" "<<x.second<<endl
#define ClearQ(x); while(!x.empty()) x.pop()
#define EPS 1e-9
#define ArrPrint(a,st,en) for(int J=st; J<=en; J++) cout<<a[J]<<" "; cout<<endl;

/* Direction Array */

// int fx[]={1,-1,0,0};
// int fy[]={0,0,1,-1};
// int fx[]={0,0,1,-1,-1,1,-1,1};
// int fy[]={-1,1,0,0,1,1,-1,-1};

template <class T> inline T bigmod(T p,T e,T M)
{
    ll ret = 1;
    for(; e > 0; e >>= 1)
    {
        if(e & 1) ret = (ret * p) % M;
        p = (p * p) % M;
    } return (T)ret;
}

template <class T> inline T gcd(T a,T b){if(b==0)return a;return gcd(b,a%b);}
template <class T> inline T modinverse(T a,T M){return bigmod(a,M-2,M);}
template <class T> inline T lcm(T a,T b) {a=abs(a);b=abs(b); return (a/gcd(a,b))*b;}
template <class T, class X> inline bool getbit(T a, X i) { T t=1; return ((a&(t<<i))>0);}
template <class T, class X> inline T setbit(T a, X i) { T t=1;return (a|(t<<i)); }
template <class T, class X> inline T resetbit(T a, X i) { T t=1;return (a&(~(t<<i)));}

inline ll getnum()
{
    char c = getchar();
    ll num,sign=1;
    for(;c<'0'||c>'9';c=getchar())if(c=='-')sign=-1;
    for(num=0;c>='0'&&c<='9';)
    {
        c-='0';
        num = num*10+c;
        c=getchar();
    }
    return num*sign;
}

inline ll power(ll a, ll b)
{
	ll multiply=1;
	FOR(i,0,b)
	{
		multiply*=a;
	}
	return multiply;
}

/****** END OF HEADER ******/

int n, k;
vpii all;

void Test()
{
	int tot=0, d=INF;

	FOR(i,0,all.size())
	{
		cout<<"For point: "<<i<<endl;
		FOR(j,i+1,all.size())
		{
			++tot;
			cout<<"tot: "<<tot<<endl;
			if(all[j].first-all[i].first>=d) break;
			d=min(d,all[j].second-all[i].second);
		}
	}

	cout<<"tot: "<<tot<<endl;
}

int main()
{
    // ios_base::sync_with_stdio(0);
    // cin.tie(NULL); cout.tie(NULL);
    // freopen("in.txt","r",stdin);

    int test, cases=1;

    cin>>n>>k;

    if(k>((ll)n*(n-1))/2) prnt("no solution");
    else
    {
    	int x=0, y=0, delta=2000;
    	for(int i=1; i<=n; i++)
    	{
    		cout<<x<<" "<<y<<endl;
    		all.pb({x,y});
    		y+=delta;
    		delta--;
    	}
    	// Test();
    }

    return 0;
}


#include<bits/stdc++.h>
#define long long long
using namespace std;
const int N=1e6;
pair<double,double>p[N+2];
double dis(pair<double,double>p1,pair<double,double>p2)
{
  return sqrt((p1.first-p2.first)*(p1.first-p2.first)+(p1.second-p2.second)*(p1.second-p2.second));
}
int main()
{
  ios_base::sync_with_stdio(0);cin.tie(0);

  int n,k;cin>>n>>k;
  //cout<<(n*(n-1))/2<<endl;
  if(k>=(n*(n-1))/2)cout<<"no solution"<<endl,exit(0);

  int x=0,y=-1000000000;
  for(int i=1;i<=n;i++)
  {
    p[i]={x,y};x++;y+=10000;
    cout<<x<<" "<<y<<endl;
  }
  // double d=1e14;int cnt=0;
  // for(int i=1;i<=n;i++)
  // {
  //   for(int j=i+1;j<=n;j++)
  //   {
  //     cnt++;
  //     if(p[j].first-p[i].first>=d)break;
  //     d=min(d,dis(p[i],p[j]));
  //   }
  // }
  // cout<<p[n].second<<endl;
  // cout<<cnt<<endl;
  return 0;
}


#include<bits/stdc++.h>
#define long long long
using namespace std;
const int N=1e6;
pair<double,double>p[N+2];
double dis(pair<double,double>p1,pair<double,double>p2)
{
  return sqrt((p1.first-p2.first)*(p1.first-p2.first)+(p1.second-p2.second)*(p1.second-p2.second));
}
int main()
{
  ios_base::sync_with_stdio(0);cin.tie(0);

  int n,k;cin>>n>>k;
  //cout<<(n*(n-1))/2<<endl;
  if(k>(n*(n-1))/2)cout<<"no solution"<<endl,exit(0);

  int x=0,y=-1000000000;
  for(int i=1;i<=n;i++)
  {
    p[i]={x,y};x++;y+=10000;
    cout<<x<<" "<<y<<endl;
  }
  // double d=1e14;int cnt=0;
  // for(int i=1;i<=n;i++)
  // {
  //   for(int j=i+1;j<=n;j++)
  //   {
  //     cnt++;
  //     if(p[j].first-p[i].first>=d)break;
  //     d=min(d,dis(p[i],p[j]));
  //   }
  // }
  // cout<<p[n].second<<endl;
  // cout<<cnt<<endl;
  return 0;
}


#include<bits/stdc++.h>
#define long long long
using namespace std;
const int N=1e6;
int main()
{
  ios_base::sync_with_stdio(0);cin.tie(0);

  int n,k;cin>>n>>k;
  if(k>(n*(n-1))/2)cout<<"no solution"<<endl,exit(0);

  int x=0,y=-1e9;
  while(n--)
  {
    cout<<x<<" "<<y<<endl;
    x++;y+=1e6;
  }
  return 0;
}


#include<bits/stdc++.h>
using namespace std;
#define ll long long
int main(){
  ll n,k; cin>>n>>k;
  ll p=(n*(n-1))/2;
  if(p<k){cout<<"no solution";}
  else{
    for(int i=0;i<n;i++){
        cout<<0<<" "<<i<<endl;
    }
  }
}


#include<bits/stdc++.h>
using namespace std;
#define ll long long
int main(){
  ll n,k; cin>>n>>k;
  ll p=(n*(n-1))/2;
  if(p<=k){cout<<"no solution";}
  else{
    for(int i=0;i<n;i++){
        cout<<0<<" "<<i<<endl;
    }
  }
}


#include<bits/stdc++.h>
using namespace std;
#define ll long long
int main(){
  ll n,k; cin>>n>>k;
  ll p=(n*(n-1))/2;
  if(p<k){cout<<"no solution";}
  else{
    for(int i=0;i<n;i++){
        cout<<i<<" "<<0<<endl;
    }
  }
}


//
//  main.cpp
//  nik codeforces problems
//
//  Created by PREEYADARSHEE DEV on 15/06/18.
//  Copyright © 2018 PREEYADARSHEE DEV. All rights reserved.
//
#include<iostream>
#include<algorithm>
#include<vector>
#include<math.h>
#include<map>
#include<string>
#include<stack>
#include<queue>
#include<deque>
#define INF (long long)1<<60
using namespace std;
int main()
{
    int n,k;
    scanf("%d %d",&n,&k);
    if(k>=2*n-1)
    {
        printf("no solution\n");
    }
    else
    {
        int i=0;
        for(int k=0;k<n;k++)
        {
            printf("%d %d\n",i+n-k,i+n-k);
            i=i+n-k;
        }
    }
}


n = raw_input()
n = int(n)

a = map(int, raw_input().split(' '))

for j in xrange(n+1):
	for i in xrange(n):
		if i%2 == 0:
			a[i] += 1
			if a[i] > n-1:
				a[i] -= n
		else:
			a[i] -= 1
			if a[i] < 0:
				a[i] += n
	if a == range(n):
		print "Yes"
		exit()
print "No"


n = raw_input()
n = int(n)

a = map(int, raw_input().split(' '))

for j in xrange(n**n):
	for i in xrange(n):
		if i%2 == 0:
			a[i] += 1
			if a[i] > n-1:
				a[i] -= n
		else:
			a[i] -= 1
			if a[i] < 0:
				a[i] += n
	if a == range(n):
		print "Yes"
		exit()
print "No"


import sys
sys.stdin=open('test.in','r')

n=input()
m = raw_input()
a = map(int, m.strip().split(' '))
print a
for i in range(0, n, 2):
    a[i] = (n + a[i] - i) % n
for i in range(1, n, 2):
    a[i] = (n - a[i] + i) % n

for i in range(1, n):
    if a[i] != a[0]:
        print 'No'
        exit()
print 'Yes'


#import sys
#sys.stdin=open('test.in','r')

n=input()
m = raw_input()
a = map(int, m.strip().split(' '))
#print a
for i in range(0, n, 2):
    a[i] = (n + a[i] - i) % n
for i in range(1, n, 2):
    a[i] = (n - a[i] + i) % n

s = False
for i in range(1, n):
    if a[i] != a[0]:
        s = True
if s:
    print 'No'
else:
    print 'Yes'


#import sys
#sys.stdin=open('test.in','r')

n=input()
m = raw_input()
a = map(int, m.strip().split(' '))
print a
for i in range(0, n, 2):
    a[i] = (n + a[i] - i) % n
for i in range(1, n, 2):
    a[i] = (n - a[i] + i) % n

for i in range(1, n):
    if a[i] != a[0]:
        print 'No'
        exit()
print 'Yes'


#import sys
#sys.stdin=open('test.in','r')

n=input()
m = raw_input()
a = map(int, m.strip().split(' '))
print a
for i in range(0, n, 2):
    a[i] = (n + a[i] - i) % n
for i in range(1, n, 2):
    a[i] = (n - a[i] + i) % n

s = False
for i in range(1, n):
    if a[i] != a[0]:
        s = True
if s:
    print 'No'
else:
    print 'Yes'


import sys, math
def rs():
    return sys.stdin.readline().strip()
def ri():
    return int(sys.stdin.readline().strip())
def ras():
    return list(sys.stdin.readline().strip())
def rai():
    return map(int,sys.stdin.readline().strip().split())
def raf():
    return map(float,sys.stdin.readline().strip().split())

def solve():
    n = ri()
    arr = rai()
    result = tuple(range(n))
    for x in xrange(n):
        for i in xrange(n):
            if i%2:
                arr[i] = (arr[i] + 1) % n
            else:
                arr[i] = (arr[i] - 1) % n
        if tuple(arr) == result:
            return "Yes"
    return "No"

print solve()


import sys, math
def rs():
    return sys.stdin.readline().strip()
def ri():
    return int(sys.stdin.readline().strip())
def ras():
    return list(sys.stdin.readline().strip())
def rai():
    return map(int,sys.stdin.readline().strip().split())
def raf():
    return map(float,sys.stdin.readline().strip().split())

def solve():
    n = ri()
    arr = rai()
    result = tuple(range(n))
    for x in xrange(n):
        for i in xrange(n):
            if i%2:
                arr[i] = (arr[i] + 1) % n
            else:
                arr[i] = (arr[i] - 1) % n
            if tuple(arr) == result:
                return "Yes"
    return "No"

print solve()


n = int(raw_input())
r = raw_input()
l = r.split(' ')
l = [int(i) for i in l]
length = len(l)
a = 0
if l[0]!= 0:
	a = n-l[0]
for x in range(1,length):
	if x%2!=0:
		b = l[x]-a
		if l[x]-a<0:
			b = n + l[x] - a
		if b!=x:
			print 'No'
			exit(0)

	else:
		b = a+l[x]
		if a+l[x]>n:
			b = n - l[x]
		if b!=x:
			print 'No'
			exit(0)
print 'Yes'


n = int(raw_input())
r = raw_input()
l = r.split(' ')
l = [int(i) for i in l]
length = len(l)
a = 0
if l[0]!= 0:
	a = n-l[0]
for x in range(1,length):
	if x%2!=0:
		b = l[x]-a
		if l[x]-a<0:
			b = n + l[x] - a
		if b!=x:
			print 'No'
			exit(0)

	else:
		b = a+l[x]
		if a+l[x]>n:
			b = b-n
		if b!=x:
			print 'No'
			exit(0)
print 'Yes'


n=input()
a=map(int,raw_input().split())
print "Yes" if all(i==(a[i]+(-1)**i*(n-a[0]))%n for i in range(n)) else "No"


if __name__== "__main__":
    n=input()
    a=map(int,raw_input().split())
    s1=''.join(map(str,a))
    b=[]
    for i in range(n):
        b.append(str(i))
    s2=''.join(b)
    while True:
        c=[]
        for i in range(n):
            if i%2:
                a[i]-=1
                if a[i]==-1:
                    a[i]=n-1
            else:
                a[i]+=1
                if a[i]==n:
                    a[i]=0
            c.append(str(a[i]))
        s3=''.join(c)
        if s2==s3:
            print "Yes"
            break
        elif s1==s3:
            print "NO"
            break


n = input()
a = [int(i) for i in raw_input().split()]
for i in xrange(n):
    if (a[i]+((-1)**(i%2))*(n-a[0]))%n!=i:
        print "No"
        break
else:
    print "Yes"


n = int(raw_input())
a = [int(item) for item in raw_input().split()]

time1 = n-a[0]
for i in xrange(n):
    if i%2==0:
        a[i] = (a[i]+time1)%n
    else:
        a[i] = (a[i]-time1)%n
if a == range(n):
    print "Yes"
else:
    print "No"


def findFirstTooth(gear, activeTooth,firstTooth, target):
    pushes = 0
    i = activeTooth
    while(firstTooth != target):
    i += 1
    pushes += 1
        if(i >= len(gear)):
        i = i % len(gear)
    firstTooth = gear[i]
    return pushes,firstTooth

def findNextTooth(gear, activeTooth,  target, pushes):
    i = activeTooth + pushes
    #print i
    if(i >= len(gear)):
        i = i % len(gear)
    nextTooth = gear[i]
    return nextTooth == target, nextTooth

n = int(raw_input())
gears = [ [0]*n for x in range(n)]
for i in range(n):
    for j in range(n):
    gears[i][j] = j
activesTooth = raw_input().split()
firstTooth = -1
clockwise = True
activeTooth = gears[0][int(activesTooth[0])]
pushes, firstTooth = findFirstTooth(gears[0], activeTooth,firstTooth, 0)
sortedActivesTooth = []
sortedActivesTooth.append(firstTooth)
isFake = False
target = 1
for i in xrange(1,len(activesTooth)):
    clockwise = not clockwise
    pushes = -pushes
    activeTooth = gears[i][int(activesTooth[i])]
    found, nextTooth = findNextTooth(gears[i], activeTooth, target, pushes)
   # print "target: {} tooth found: {}".format(target,nextTooth)
    if(not found):
    print "No"
    isFake = True
    break
    else:
    sortedActivesTooth.append(nextTooth)
    target += 1
if(not isFake):
    print "Yes"


def findFirstTooth(gear, activeTooth,firstTooth, target):
    pushes = 0
    i = activeTooth
    while(firstTooth != target):
	i += 1
	pushes += 1
        if(i >= len(gear)):
	    i = i % len(gear)
	firstTooth = gear[i]
    return pushes,firstTooth

def findNextTooth(gear, activeTooth,  target, pushes):
    i = activeTooth + pushes
    #print i
    if(i >= len(gear)):
	    i = i % len(gear)
    nextTooth = gear[i]
    return nextTooth == target, nextTooth

n = int(raw_input())
gears = [ [0]*n for x in range(n)]
for i in range(n):
    for j in range(n):
	gears[i][j] = j
activesTooth = raw_input().split()
firstTooth = -1
clockwise = True
activeTooth = gears[0][int(activesTooth[0])]
pushes, firstTooth = findFirstTooth(gears[0], activeTooth,firstTooth, 0)
sortedActivesTooth = []
sortedActivesTooth.append(firstTooth)
isFake = False
target = 1
for i in xrange(1,len(activesTooth)):
    clockwise = not clockwise
    pushes = -pushes
    activeTooth = gears[i][int(activesTooth[i])]
    found, nextTooth = findNextTooth(gears[i], activeTooth, target, pushes)
   # print "target: {} tooth found: {}".format(target,nextTooth)
    if(not found):
	print "No"
	isFake = True
	break
    else:
	sortedActivesTooth.append(nextTooth)
    target += 1
if(not isFake):
    print "Yes"


#map(int,raw_input().split()
#for xxx in xrange():
def f(n,a):
    if (n==(a-1)):
        return 0
    else:
        return n+1
def g(n,a):
    if (n==0):
        return a-1
    else:
        return n-1
def proc(s):
    for i in xrange(len(s)):
        if i%2==0:
            s[i]=f(s[i],x)
        else:
            s[i]=g(s[i],x)
    return s

x=input()
y=map(int,raw_input().split())
s=y
z=range(x)
while(1):
    if (proc(s)==z):
        print 'Yes'
        break
    if(proc(s)==y):
        print 'No'
        break


def f(n,a):
    if (n==(a-1)):
        return 0
    else:
        return n+1
def g(n,a):
    if (n==0):
        return a-1
    else:
        return n-1
def proc(s):
    for i in xrange(len(s)):
        if i%2==0:
            s[i]=f(s[i],x)
        else:
            s[i]=g(s[i],x)
    return s

x=int(raw_input())
y=map(int,raw_input().split())
s=y
z=range(x)
while(1):
    g=proc(s)
    if (g==z):
        print 'Yes'
        break
    if(g==y):
        print 'No'
        break


def f(n,a):
    if (n==(a-1)):
        return 0
    else:
        return n+1
def g(n,a):
    if (n==0):
        return a-1
    else:
        return n-1
def proc(s):
    for i in xrange(len(s)):
        if i%2==0:
            s[i]=f(s[i],x)
        else:
            s[i]=g(s[i],x)
    return s

x=int(raw_input())
y=map(int,raw_input().split())
s=y[:]
z=range(x)
while(1):
    t=proc(s)
    if (t==z):
        print 'Yes'
        break
    if(t==y):
        print 'No'
        break


def f(n,a):
    if (n==(a-1)):
        return 0
    else:
        return n+1
def g(n,a):
    if (n==0):
        return a-1
    else:
        return n-1
def proc(s):
    for i in xrange(len(s)):
        if i%2==0:
            s[i]=f(s[i],x)
        else:
            s[i]=g(s[i],x)
    return s

x=int(raw_input())
y=map(int,raw_input().split())
s=y
z=range(x)
while(1):
    g=proc(z)
    if (g==z):
        print 'Yes'
        break
    if(g==y):
        print 'No'
        break


#!/usr/bin/python

from collections import deque

def ir():
    return int(raw_input())

def ia():
    line = raw_input()
    line = line.split()
    return map(int, line)

def step():
    c, p = 1, -1
    for i in range(n):
        a[i] += c
        if a[i] <0: a[i] = n - 1
        if a[i]>=n: a[i] = 0
        c, p = p, c

n = ir()
a = ia()

def solve():
    ref = list(range(n))
    for i in range(n+2):
        if a == ref:
            print 'YES'
            return
        step()

    print 'NO'

solve()


n = int(raw_input())

arr = [int(x) for x in raw_input().split()]

diff = len(arr) - arr[0]
if arr[0] == 0:
    diff = 0
flag = True

for i in xrange(1, len(arr)):
    if i % 2 != 0:
        # anticlockwise
        have = arr[i]
        becomes = (arr[i] + (len(arr) - diff)) % len(arr)
        if becomes != i:
            flag = False

    else:
        # clockwise
        becomes = (arr[i] + diff) % len(arr)
        if becomes != i:
            flag = False

if not flag:
    print "No"
else:
    print "Yes"


# coding: utf-8

# Verifica se foi possivel deixar as engrenagens nas posições corretas
def possivel(nums):
	for i in range(len(nums)):
		if nums[i] != i:
			return False
	return True

n = int(raw_input())

pos_engrenagens = map(int, raw_input().split())

# O único jeito de deixar as engrenagens ordenadas é apertando os botões até que a primeira esteja na posição 0 (zero), então
# já podemos determinar quantos movimentos são necessários
movimentos_necessarios = n - pos_engrenagens[0]

for i in range(n):
	# Se as engrenagens estão em um indice par, realizamos os movimentos necessários em sentido horário
	# Caso contrário, realizamos os movimentos necessários no sentido anti-horário
	if i % 2 == 0:
		pos_engrenagens[i] += movimentos_necessarios
		pos_engrenagens[i] %= n
	else:
		pos_engrenagens[i] = n - (movimentos_necessarios - pos_engrenagens[i])
		pos_engrenagens[i] %= n

if possivel(pos_engrenagens): print "Yes"
else: print "No"


# -*- coding: utf-8 -*-

# Universidade Federal de Campina Grande
# Aluno: Diego Adolfo Silva de Araújo
# Matricula: 113210090
# Disciplina: Algoritmos Avançados

# Codeforces
# Problem: 556B - B. Case of Fake Numbers
# Time limit per test: 2 second
# Memory limit per test: 256 megabytes
# Input: standard input
# Output: standard output

gears = int(raw_input())
teeth = map(int, raw_input().split())

tooth = teeth[0]
for index, value in enumerate(teeth):
    value += tooth if index % 2 else -tooth

    if value < 0:
        value += gears
    elif value >= gears:
        value -= gears

    teeth[index] = value

answer = 'No'
if teeth == range(gears):
    answer = 'Yes'

print answer


n = int(raw_input())
l = map(int, raw_input().split())
Got = 1

while l[0] != 0 :

    for i in range(0,n) :

        if i % 2 == 0 :

            if l[i] == n - 1 :

                l[i] = 0

            else :

                l[i] = l[i] + 1

        else :

            if l[i] == 0 :

                l[i] = n - 1

            else :

                l[i] = l[i] - 1

for x in range(1,n) :

    if l[x] - l[x-1] != 1 :

        Got = 0
        break

if Got == 1 :

    print 'YES'

else :

    print 'NO'


n = int(raw_input())
l = map(int, raw_input().split())
Got = 1

while l[0] != 0 :

    for i in range(0,n) :

        if i % 2 == 0 :

            l[i] = (l[i] + 1)%n

        else :

            if l[i] != 0 :

                l[i] = l[i] - 1

            else :

                l[i] = n - 1

for x in range(1,n) :

    if l[x] - l[x-1] != 1 :

        Got = 0
        break

if Got == 1 :

    print 'YES'

else :

    print 'NO'


n = int(raw_input())
l = map(int, raw_input().split())
Got = 1

while True :

    if l[0] == 0 :

        for x in range(1,n) :

            if l[x] - l[x-1] != 1 :

                Got = 0
                break

        break

    else :

        for i in range(0,n) :

            if i % 2 == 0 :

                if l[i] == n - 1 :

                    l[i] = 0

                else :

                    l[i] = l[i] + 1

            else :

                if l[i] == 0 :

                    l[i] = n - 1

                else :

                    l[i] = l[i] - 1

if Got == 1 :

    print 'YES'

else :

    print 'NO'


n = int(raw_input())
l = map(int, raw_input().split())
Got = 1

while l[0] != 0 :

    for i in range(0,n) :

        if i % 2 == 0 :

            if l[i] != n - 1 :

                l[i] = l[i] + 1

            else :

                l[i] = 0

        else :

            if l[i] != 0 :

                l[i] = l[i] - 1

            else :

                l[i] = n - 1

for x in range(1,n) :

    if l[x] - l[x-1] != 1 :

        Got = 0
        break

if Got == 1 :

    print 'YES'

else :

    print 'NO'


n=input()
a=map(int,raw_input().split())
push=n-a[0]
clockwise=True
fake=False
for i in range(n):
    if clockwise:
        if (a[i]+push)%n !=i:
            fake=True
    else:
        if (a[i]-push)%n !=i:
            fake=True
    clockwise= not clockwise

if fake:
    print 'No'
else:
    print 'Yes'


n=int(raw_input())
a = map(int,raw_input().split())
a1=a[0]
if a1 != 0:
     rot = n-a1
else:
    rot =0
flag = True
for i in range (n):
    if i % 2 ==0:
        a[i] = a[i] + rot
        if a[i] > n-1:
            a[i] = a[i] - n
    else:
        a[i] = a[i] - rot
        if a[i] <0:
            a[i] += n
    if a[i] != i:
        flag = False
        break
if flag:
    print 'YES'
else:
    print 'NO'


n=int(raw_input())
arr=map(int,raw_input().split())
#print arr

ini=0
flag=1
for i in range(n):
	c=0
	ini=0
	for x in arr:
		if(x!=ini):
			break
		c+=1
		ini+=1
	#print arr
	if(c!=n):
		ini=0
		while(ini<len(arr)):
			if(ini%2==0):
				arr[ini]=(arr[ini]+1)%n
			else:
				arr[ini]=(arr[ini]-1)%n
			ini+=1
	else:
		flag=0
		break

if(flag==0):
	print "Yes"
else:
	print "No"


n=int(raw_input())
arr=map(int,raw_input().split())
#print arr

ini=0
amt=0
n-=1
flag=0
for x in arr:
	#print x
	if(ini==0 and ini%2==0):
		amt=n-x+1
	elif(ini%2==0):
		temp=0
		if(ini>=x):
			temp=ini-x
		else:
			temp=(n-ini)+x+1

		if(amt==temp or (temp==0 and amt==n+1)):
			temple=0
		else:
			flag=1
	else:
		temp=0
		if(ini>=x):
			temp=x+(n-ini)+1
		else:
			temp=x-ini

		if(amt==temp or (temp==0 and amt==n+1)):
			temple=0
		else:
			flag=1

	if(flag==1):
		break
	ini+=1

if(flag==0):
	print "Yes"
else:
	print "No"


n=int(raw_input())
arr=map(int,raw_input().split())
#print arr

ini=0
amt=0
n-=1
flag=0
for x in arr:
	#print x
	if(ini==0 and ini%2==0):
		amt=n-x+1
	elif(ini%2==0):
		temp=0
		if(ini>=x):
			temp=ini-x
		else:
			temp=(n-ini)+x+1

		if(amt==temp or (temp==0 and amt==n)):
			temple=0
		else:
			flag=1
	else:
		temp=0
		if(ini>=x):
			temp=x+(n-ini)+1
		else:
			temp=x-ini

		if(amt==temp or (temp==0 and amt==n)):
			temple=0
		else:
			flag=1

	if(flag==1):
		break
	ini+=1

if(flag==0):
	print "Yes"
else:
	print "No"


if __name__ == '__main__':
    n = input()
    a = [int(x) for x in raw_input().split()]

    rotate_cnt = n - a[0] if a[0] else a[0]
    for i, ai in enumerate(a):
        if i % 2 == 0: # clockwise
            a[i] = (a[i] + rotate_cnt) % n
        else: # counter-clockwise
            a[i] = a[i] - rotate_cnt
            if a[i] < 0:
                a[i] = n + a[i]

    form_sequence = True
    for i, ai in enumerate(a):
        if i != ai:
            form_sequence = False
            break

    if form_sequence:
        print 'Yes'
    else:
        print 'No'


#br = open('b.in')
n = int(raw_input())
v = map(int, raw_input().split())

u = set()

while 1:
  for i in range(n):
    v[i] += [1, -1][i % 2]
    v[i] %= n
  if all(i == e for i, e in enumerate(v)):
    print "Yes"
    exit(0)
  if tuple(v) in u:
    break
  u.add(tuple(v))

print "No"


n=input()
l=map(int,raw_input().split())
c=(n-l[0])
for i in range(n):
    if (i % 2):
        l[i] -= c
    else:
        l[i] +=c
    l[i] %=n

print ['No','Yes'][l == range(n)]


n=input()
l=map(int,raw_input().split())
c=(n-l[0])
for i in range(n):
    if (i % 2):
        l[i] -= c
    else:
        l[i] +=c
    l[i] %=5
print ['No','Yes'][l == range(n)]


def sol():
    n=int(raw_input())
    l=map(int,raw_input().split())
    chk=range(n)
    e=0
    while e<n:
        e+=1
        cnt=0
        while cnt<n:
            if cnt%2:
                l[cnt]-=1
            else:
                l[cnt]+=1
            if l[cnt]==-1:
                l[cnt]=n-1
            elif l[cnt]==n:
                l[cnt]=0
            cnt+=1
        if l==chk:
            return 1

    return 0

print 'Yes' if sol() else 'No'


def sol():
    n=int(raw_input())
    l=map(int,raw_input().split())
    chk=range(n)
    while n:
        cnt=0
        while cnt<n:
            if cnt%2:
                l[cnt]-=1
            else:
                l[cnt]+=1
            if l[cnt]==-1:
                l[cnt]=n-1
            elif l[cnt]==n:
                l[cnt]=0
            cnt+=1
        if l==chk:
            return 1

    return 0

print 'Yes' if sol() else 'No'


n = int(input())
x = map(int, raw_input().split())

def solve():
    d = (n - x[0]) % n
    for i in xrange(1, n):
        if (i & 1):
            if (x[i] - d) % n != i:
                print "No"
                return
        else:
            if (x[i] + d) % n != i:
                print "No"
                return
    print "Yes"

solve()


n = int(raw_input())
l = map(int,raw_input().split())
c=(n-l[0])
for i in range(n):
    if (i % 2):
        l[i] -= c
    else:
        l[i] +=c
    l[i] %= n

print ['No', 'Yes'][l == range(n)]


def rotate(a):
	global A, n
	for i in xrange(n):
		if i % 2 == 0: A[i] += a
		else: A[i] -= a
		if A[i] == -1: A[i] = n - 1
		if A[i] == n: A[i] = 0

n = input()
A = map(int, raw_input().split())
A_, ans, k = A[:], 'No', A[0]
for _ in xrange(k):
	rotate(-1)
if A == range(n):
	ans = 'Yes'
if ans == 'No':
	A = A_[:]
	for _ in xrange(n - k):
		rotate(1)
if A == range(n):
	ans = 'Yes'

print ans


n=input()
a=map(int,raw_input().split())
x=n-a[0]
print(['No','Yes'][[(a[i]+((-1)**i)*x+n)%n for i in range(n)]==range(n)])


# CASE OF FAKE NUMBERS
# Estacio Pereira, estacio.neto@ccc.ufcg.edu.br
# UFCG

# INPUT
n = int(raw_input())
numbers = raw_input().split()
lista = []
listas = []
for i in range(len(numbers)):
    numbers[i] = int(numbers[i])
# PROCESS
for e in range(n):
    lista.append(e)
passa = False
while not lista in listas:
    listas.append(lista[::])
    for i in range(len(lista)):
        if not (i + 1) % 2:
            if lista[i] == n - 1:
                lista[i] = 0
            else:
                lista[i] += 1
        elif (i + 1) % 2:
            if not lista[i]:
                lista[i] = n - 1
            else:
                lista[i] -= 1
    if lista == numbers:
        passa = True
        break
# OUTPUT
if passa:
    print "YES"
else:
    print "NO"


# -*- coding:utf-8 -*-
import sys
def some_func():
    """
    """
    n = input()
    n_list = map(int, sys.stdin.readline().split())

    cache_x = {}
    cache_y = {}
    for i in range(n):
        cache_x[i]=(i+1)%n
        cache_y[i]=(i-1)%n

    while True:
        if n_list[0]==0:
            break
        else:
            for i in range(n):
                if i%2:
                    n_list[i] = cache_y[n_list[i]]
                else:
                    n_list[i] = cache_x[n_list[i]]

    for i in range(len(n_list)):
        if i!=n_list[i]:
            print 'No'
            return

    print 'Yes'
    return

if __name__ == '__main__':
    some_func()


# -*- coding:utf-8 -*-
import sys
def some_func():
    """
    """
    n = input()
    n_list = map(int, sys.stdin.readline().split())

    cache_x = {}
    cache_y = {}
    for i in range(n):
        cache_x[i]=(i+1)%n
        cache_y[i]=(i-1)%n

    while True:
        if n_list[0]==0:
            break
        else:
            for i in range(n):
                if i%2:
                    n_list[i] = cache_y[n_list[i]]
                else:
                    n_list[i] = cache_x[n_list[i]]

    for v in n_list:
        if v!=n_list[v]:
            print 'No'
            return
        else:
            print 'Yes'
            return

if __name__ == '__main__':
    some_func()


x = raw_input()
y = map(int, raw_input().split())
z = y[0]
def changegears():
	l = []
	i = 0
	while i < x:
		nimi = i % 2
		propersign = 2* nimi - 1
		u = y[i]
		gear = z*propersign + u
		fat = gear % x
		l.append(fat)
		i += 1
	return l

fatter = []
j = 0
while j < x:
	fatter.append(j)
	j += 1

if fatter == changegears():
	print "Yes"
else:
	print "No"


a = raw_input()
x = int(a)
y = map(int, raw_input().split())
z = y[0]
def changegears():
	l = []
	i = 0
	while i < x:
		nimi = i % 2
		propersign = 2* nimi - 1
		u = y[i]
		gear = z*propersign + u
		fat = gear % x
		l.append(fat)
		i += 1
	return l

fatter = []
j = 0
while j < x:
	fatter.append(j)
	j += 1

if fatter == changegears():
	print "Yes"
else:
	print "No"


n = int(raw_input().strip())
settings = map(int, raw_input().strip().split(' '))
diff = settings[0]
for i in xrange(len(settings)):
    if i % 2 == 0:
        if (settings[i] - diff) % n != i:
            print 'No'
            exit()
    else:
        if (settings[i] + diff) % n != i:
            print 'No'
            exit()

print 'Yes'


#!/usr/bin/env python
# -*- coding: utf-8 -*-

import sys

def read_in():
    lines = list()
    for line in sys.stdin:
        line = line.replace('\n', '')
        lines.append(line)
    # print lines
    return lines

def toy_cars(lines):
    lines = lines[1:]
    # print lines
    good_set = set()
    bad_set = set()
    for i in range(len(lines)):
        cul_list = lines[i].split(' ')
        for j in range(len(cul_list)):
            if cul_list[j] == '-1':
                if len(lines) == 1 and len(cul_list) == 1:
                    good_set.add(i+1)
                pass
            elif cul_list[j] == '0':
                good_set.add(i+1)
                good_set.add(j+1)
            elif cul_list[j] == '1':
                good_set.add(j+1)
                bad_set.add(i+1)
                pass
            elif cul_list[j] == '2':
                good_set.add(i+1)
                bad_set.add(j+1)
                pass
            elif cul_list[j] == '3':
                bad_set.add(i+1)
                bad_set.add(j+1)
                pass
            else:
                raise Exception
    result = good_set - bad_set
    sorted_result = sorted(result)
    # print result
    print len(sorted_result)
    for x in sorted_result:
        print x,

def ZerosAndOnes():
    n = int(raw_input())
    a = raw_input()
    print abs(a.count('1')-a.count('0'))

def FakeNumbers():
    n = int(raw_input())
    a = raw_input()
    check = list()
    for i in range(n):
        check.append(str(i))
    # print check
    a = a.split(' ')
    v = 'No'
    for j in range(n):
        if check == a:
            v = 'Yes'
        for i in range(n):
            if a[i] == ' ':
                continue
            if i % 2 == 0:
                a[i] = str(int(a[i]) + 1)
            else:
                a[i] = str(int(a[i]) - 1)
            if int(a[i]) < 0:
                a[i] = str(n - 1)
            if not int(a[i]) < n:
                a[i] = '0'
        # print a
    print v

def main():
    # lines = read_in()
    # print lines
    # toy_cars(lines)
    # ZerosAndOnes()
    FakeNumbers()

if __name__ == '__main__':
    main()


def is_correct_seq(a):
    for i in range(len(a) - 1):
        if a[i + 1] - a[i] != 1:
            return False

    return a[0] == 0

def button_press(a):
    q = 1
    for i in range(len(a)):
        a[i] = (a[i] + q) % len(a)
        q *= -1

def sol():
    n = input()
    a = map(int, raw_input().split())
    for i in range(n):
        button_press(a)
        if is_correct_seq(a):
            return True

    return False

if sol():
    print("Yes")
else:
    print("No")


n = int(raw_input())
inp = [int(_) for _ in raw_input().split()]
step = (n-inp[0])%n
#print step
for i in xrange(0,len(inp),2):
    #print i
    inp[i] = (inp[i]+step)%n
    #print inp
for x in xrange(1,len(inp),2):
    #print x
    inp[x] = (inp[x]-step)%n
    #print inp
li = []
for i in xrange(n):
    li.append(i)
if li == inp:
    print "Yes"
else:
    print "No"


#!/usr/bin/env python

def main():
	n = int(raw_input())
	a = map(int, raw_input().split())
	flag = True
	if n > 1:
		cnt = 0 if a[0] == 0 else n - a[0]
		for i in xrange(1, n):
			if i & 1:
				if (a[i] + n - cnt) % n != i:
					flag = False
			else:
				if (a[i] + cnt) % n != i:
					flag = False
	print 'Yes' if flag else 'No'

if __name__ == '__main__':
	main()


n=raw_input()
snorlax=raw_input().split(' ')
def bite(snorlax):
    i=0
    buttery=len(snorlax)
    while i < buttery:
        if i%2==0:
            (snorlax[i])=(int(snorlax[i])+1) % buttery
            i+=1
        else:
            (snorlax[i])=(int(snorlax[i])-1) % buttery
            i+=1
    return snorlax

i=0
S = [x for x in range(int(n))]
for i in range(int(n)+10):
    snorlax=bite(snorlax)
    if snorlax==S:
        bob=True
        break
    else:
        bob=False
if bob==True:
    print 'Yes'
if bob==False:
    print 'No'


n=raw_input()
snorlax=raw_input().split(' ')
def bite(snorlax):
    i=0
    buttery=len(snorlax)
    while i < buttery:
        if i%2==0:
            (snorlax[i])=(int(snorlax[i])+1) % buttery
            i+=1
        else:
            (snorlax[i])=(int(snorlax[i])-1) % buttery
            i+=1
    return snorlax

i=0
S = [x for x in range(int(n))]
for i in range(int(n)+10):
    snorlax=bite(snorlax)
    if (snorlax)==S:
        bob=True
        break
    else:
        bob=False
        snorlax=bite(snorlax)
        i+=1
if bob==True:
    print 'Yes'
if bob==False:
    print 'No'


n=raw_input()
snorlax=raw_input().split(' ')
def bite(snorlax):
    i=0
    buttery=len(snorlax)
    while i < buttery:
        if i%2==0:
            (snorlax[i])=(int(snorlax[i])+1) % buttery
            i+=1
        else:
            (snorlax[i])=(int(snorlax[i])-1) % buttery
            i+=1
    return snorlax

i=0
S = [x for x in range(int(n))]
for i in range(int(n)+10):
    snorlax=bite(snorlax)
    if bite(snorlax)==S:
        bob=True
        break
    else:
        bob=False
if bob==True:
    print 'Yes'
if bob==False:
    print 'No'


n=raw_input()
snorlax=raw_input().split(' ')
def bite(snorlax):
    i=0
    buttery=len(snorlax)
    while i < buttery:
        if i%2==0:
            (snorlax[i])=(int(snorlax[i])+1) % buttery
            i+=1
        else:
            (snorlax[i])=(int(snorlax[i])-1) % buttery
            i+=1
    return snorlax

i=0
S = [x for x in range(int(n))]
for i in range(int(n)+1000):
    snorlax=bite(snorlax)
    if bite(snorlax)==S:
        bob=True
        break
    else:
        bob=False
        snorlax=bite(snorlax)
        i+=1
if bob==True:
    print 'Yes'
if bob==False:
    print 'No'


#coding: utf-8

engrenagens = int(raw_input())
lista = raw_input().split()
vetor = []
vetor_real = []
for i in range(engrenagens) :
    vetor.append(lista[i])
    vetor_real.append(i)
for  j in range(engrenagens):
    if vetor_real == vetor: break
    i = 0
    while True :
        if i % 2 == 0 : k = int(vetor[i]) + 1
        else : k = int(vetor[i]) - 1
        if k < 0 : k = engrenagens - 1
        if k == engrenagens : k = 0
        vetor[i] = k
        i += 1
        if i >= engrenagens: break

if vetor_real == vetor : print "YES"
else : print "NO"


#coding: utf-8

engrenagens = int(raw_input())
lista = raw_input().split()
vetor = []
vetor_real = []
for i in range(engrenagens) :
	vetor.append(lista[i])
	vetor_real.append(i)
for  j in range(engrenagens):
	if vetor_real == vetor: break
	i = 0
	while True :
		if i % 2 == 0 : k = int(vetor[i]) + 1
		else : k = int(vetor[i]) - 1
		if k < 0 : k = engrenagens - 1
		if k == engrenagens : k = 0
		vetor[i] = k
		i += 1
		if i >= engrenagens: break

if vetor_real == vetor : print "YES"
else : print "NO"


def even(a,i,n):
    if(i>=a): return i-a
    else: return n+i-a

def odd(a,i,n):
    if(i<=a): return a-i
    else: return n+a-i

n=input()
ar=map(int,raw_input().split())
flag=True
tem=n-ar[0]
if(tem==n): tem=0
for i in range(1,n):
    if(i%2==1):
        if(odd(ar[i],i,n)!=tem):
           flag=False
           break
    else:
        if(even(ar[i],i,n)!=tem):
            flag=False
            break
if(flag): print 'Yes'
else: print 'No'


def even(a,i,n):
    if(i>=a): return i-a
    else: return n+i-a

def odd(a,i,n):
    if(i<=a): return a-i
    else: return n+a-i

n=input()
ar=map(int,raw_input().split())
flag=True
tem=n-ar[0]
for i in range(1,n):
    if(i%2==1):
        if(odd(ar[i],i,n)!=tem):
           flag=False
           break
    else:
        if(even(ar[i],i,n)!=tem):
            flag=False
            break
if(flag): print 'Yes'
else: print 'No'


n = int(raw_input())
a = map(int, raw_input().split())
if a[0] == 0:
    if a == range(n):
        print 'Yes'
    else:
        print 'No'
else:
    b = (n - a[0])%n
    c = 1
    d = False
    for i in xrange(1, n):
        if (a[i] + ((-b)*c))%n != i:
            print 'No'
            d = True
            break
        c*=(-1)
    if d == False:
        print 'Yes'


n=input()
a=map(int,raw_input().split())
print "Yes" if all(i==(a[i]+(-1)**i*(n-a[0]))%n for i in range(n)) else "No"


n= int(raw_input())
p = [int(x) for x in raw_input().split()]

req = 0-p[0]
if req < 0: req += (n)
p[0] = 0
for i in xrange(1,len(p)):
    if i%2==0:
        p[i] += req
        if p[i] > (n-1): p[i] -= n
    else:
        p[i] -= req
        if p[i] < 0: p[i] += n

correct = True
for i in xrange(len(p)):
    if p[i] != i:
        correct = False
        break

print "Yes" if correct else "No"


r = lambda :map(int,raw_input().split())
n = input()
a = r()
b = n-a[0]
for i in xrange(n):
	if i%2==0:
		if (a[i]+b)%n<>i:
			print 'No'
			exit(0)
	else:
		if (a[i]-b)%n<>i:
			print 'No'
			exit(0)
print 'Yes'


def solve(n, active):
	goal = [i for i in range(n)]
	if active == goal:
		return "Yes"
	for i in range(n):
		for x in range(n):
			if x % 2 == 0:
				active[x] += 1
				active[x] %= n
			else:
				active[x] -= 1
				if active[x] < 0:
					active[x] = n - 1
				active[x] %= n
		if active == goal:
			return "Yes"
	return "No"

n1 = int(raw_input())
active1 = map(int, raw_input().split())
print solve(n1, active1)


n = int(raw_input())
li = raw_input().split()
chec = []
for q in range(0,n):
    li[q] = int(li[q])
for k in range(0,n):
    chec.append(k)
for j in range(0,n):
    for i in range(0,n):
        if i % 2 == 0:
            li[i] = li[i] + 1
            if li[i] == n:
                li[i] = 0
            elif li[i]<0:
                li[i] = n-1
        else:
            li[i] = li[i] - 1
            if li[i] == n:
                li[i] = 0
            elif li[i]<0:
                li[i] = n-1
    if li == chec:
        print "YES"
        break
    elif j == n-1:
        print "NO"