#include<bits/stdc++.h>
#define fasterthanlight ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL)
#define endl "\n"
#define int long long
#define vi vector<int>
#define pb push_back
#define mod 1000000007
#define MAX 1e9
#define MIN -1e9
#define hi "visited\n" //sasta debugging
using namespace std;

//author::@whohet-->Het Patel

void solve()
{
	string s = "";
	int n;
	cin >> n;
	int k;
	cin >> k;
	for (int i = 0; i < k; i++)
	{
		s += ('a' + i);
		for (int j = i + 1; j < k; j++)
		{
			s += ('a' + i);
			s += ('a' + j);
		}
	}
	int m = s.length();
	for (int i = 0; i < n; i++)
		cout << s[i % m];
}

signed main()
{
	fasterthanlight;
	int T; T = 1;
	//cin >> T;
	while (T--)
	{
		solve();
	}

	//cout << "\n\n"<<"Time elapsed: " << 1.0 * clock() / CLOCKS_PER_SEC << " seconds.\n";
	return 0;
}