#include<iostream>
#include<stack>
#include<string>
#include<set>
#include<map>
#include<vector>
#include<math.h>
#include<functional>
#include<limits.h>
#include<utility>
#include<queue>
#include<algorithm>
#include<cstring>
#include<iomanip>
#include<bitset>
#include<time.h>
#define lowbit(x) ((x)&(-x))
typedef long long ll;
//
const int maxn = 2e5 + 10;
const int maxm = 2e5 + 10;
const int inf = 0x3f3f3f3f;
const ll mod = 1e9 + 7;
const double eps = 1e-7;
using namespace std;
typedef pair<int, int> pii;
/*ll gcd(ll a, ll b)//���Լ��
{
return b == 0 ? a : gcd(b, a%b);
}
ll lcm(ll a, ll b)
{
return a / gcd(a, b)*b;
}
ll fast_pow(ll a, ll k)//������
{
ll ans = 1;
a = a%mod;
while (k != 0)
{
if (k & 1) ans = (ans*a) % mod;
k >>= 1;
a = (a*a) % mod;
}
return ans;
}
ll C(ll n, ll m)
{
return ((fac[n] * fast_pow(fac[m], mod - 2))%mod*fast_pow(fac[n - m], mod - 2)%mod);
}

bool is_prime(ll x)//�����ж�
{
if (x == 2 || x == 3) return true;
if (x % 6 != 1 && x % 6 != 5) return false;
ll temp = sqrt(1.0*x);
for (ll i = 5;i <= temp;i += 6)
if (x%i == 0 || x % (i + 2) == 0) return false;
return true;
}
int prime[maxm], pnum = 0;//������pnum������
bool p[maxm] = { 0 };//�����ɸ������Ϊtrue
void Find_Prime()//�����ɸѡ��������һ���������Ͱ����ı���ȫ��ɸ��
{
for (int i = 2;i < maxm;i++)
{
if (p[i] == false)//����һ����һ�������ж�������
{
prime[pnum++] = i;
for (int j = i + i;j < maxm;j += i)//ɸ�������ı���
p[j] = true;
}
}
}

void Exgcd(ll a, ll b, ll &x, ll &y) {
if (!b) x = 1, y = 0;
else Exgcd(b, a % b, y, x), y -= a / b * x;
}//x��a��mod b�µ���Ԫ
ll CRT(int a[],int m[],int n)
{
ll M=1,ans=0,t,x,y;
for(int i=0; i<n; i++)
{
M*=m[i];///MΪ�����˻�
}
for(int i=0; i<n; i++)
{
t=M/m[i];///����mi�����n-1�������˻�
Exgcd(t,m[i],x,y);///����Ԫ������չŷ�����ת����t*ti+m[i]*y=1����ti
ans=(ans+a[i]*x*t)%M;
}
return (ans+M)%M;
}
struct Edge
{
int to, next;
}edge[maxn<<1];
int cnt, head[maxn];
void add_edge(int u, int v)
{
edge[++cnt].next = head[u];
edge[cnt].to = v;
head[u] = cnt;
}*/
int n, k;
string ans;
int main() {
	ios::sync_with_stdio(false);
	cin.tie(0); cout.tie(0);
	int T;
	cin >> T;
	while (T--)
	{
		cin >> n >> k;
		ans.clear();
		int p = n - k;
		while (k--)
			ans.push_back('a');
		for (int i = 0; i < p; i++)
		{
			if(i%3==0)
				ans.push_back('b');
			else if(i%3==1)
				ans.push_back('c');
			else ans.push_back('a');
		}
		cout << ans << endl;
	}
	return ~~(0 - 0);
}