#include <bits/stdc++.h>
#pragma comment(linker, "/STACK:102400000,102400000")
using namespace std;
const int inf = 0x3f3f3f3f;
const long long llf = 0x3f3f3f3f3f3f3f3f;
const int maxn = (int)1e6 + 7;
const double eps = 1e-10;
const long long mod1 = (int)1e9 + 7;
const long long mod2 = 998244353;
const long long has = 99959;
const int dx[] = {0, 1, 0, -1};
const int dy[] = {1, 0, -1, 0};
int main() {
  std::ios::sync_with_stdio(false);
  int n, k;
  cin >> n >> k;
  string str;
  int num = 0;
  for (int i = 1; i < n; i = num) {
    for (int j = 1; j <= k && num < n; ++j) {
      str += (char)('a' + j - 1);
      num++;
    }
  }
  cout << str << endl;
  return 0;
}
