#include<stdio.h>
#include<iostream>
#include<cstring>
#define ll long long
using namespace std;
ll x,y,a,b,g;
int main(){
	
	cin>>x>>y>>a>>b;
	
    while((double)a*x<=x+b && a*x<y){
       x*=a;
       g++;  
    }
     
    cout<<g + (y-1-x)/b<<endl;
    return 0;
}

#define _USE_MATH_DEFINES
#include <bits/stdc++.h>

using namespace std;
#define rep(i, n) for (ll i = 0; i < (ll)(n); (i)++)
#define per(i, n) for (ll i = n - 1; i >= 0; (i)--)
#define FOR(i, a, b) for (ll i = (a); i < (b); i++)
#define ROF(i, a, b) for (ll i = (b) - 1; i >= (a); i--)
#define ALL(x) std::begin(x), std::end(x)

typedef long long ll;

int main(){
    //input, initialize
    ll A, B, K; cin >> A >> B >> K;
    //solve
    vector<vector<ll>> combi(A+B+1, (vector<ll>(A+B+1, 0)));
    rep(i, A+B+1) combi[i][0] = 1;
            // combi[i][j] := iCjを表す
    FOR(i, 1, A+B+1)FOR(j, 1, i+1){
        combi[i][j] = combi[i][j-1] * (i - j + 1) / j;
    }
    vector<bool> Bspot(A+B+1); //Bspot[i] := ひだりからi番目(1-based)のBの位置
    ROF(i, 1, B+1)FOR(j, i, A+B+1){
        if(combi[j][i] >= K){
            Bspot[j] = true;
            K -= combi[j-1][i]; // j == i のときは0が引かれてそのまま
            break;
        }
    }

    //output
    ROF(i, 1, A+B+1){
        if(Bspot[i]) cout << 'b';
        else cout << 'a';
    }
    cout << '\n';
}