#include<bits/stdc++.h>
using namespace std;
# define pb push_back
# define FOR(i,a,n) for(int i=a;i<n;i++)
# define mp make_pair
# define RFOR(i,a,n) for(int i=n;i>a;i--)
# define pii pair<long long int,long long int>
#define ub upper_bound
#define lb lower_bound
#define mod 1000000007
typedef long long int ll;
ll bin(ll a, ll b)
{
	if(b==0)
	return 1;
	if(b&1)
		return (a*bin((a*a)%mod,b/2))%mod;
	return (1*bin((a*a)%mod,b/2))%mod;
}
int main()
{
	ios::sync_with_stdio(0);
	cin.tie(0);
        cout.tie(0);
	int t ;
	cin>>t;
	while(t--)
	{
		ll n,k;
		cin>>n>>k;
		string str;
		ll cnt1=0;
		for(int i=0;i<n;i++)
		{
			ll cnt=cnt1/k;
			if(cnt%3==0)
			str+='a';
			else if(cnt%3==1)
			str+='b';
			else
			str+='c';
			cnt1++;
		}
		cout<<str<<endl;
	}
}
