#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, k, m;
  string s = "";
  cin >> n >> k;
  int f = 0;
  while (n) {
    int x = n;
    for (int i = 0; i < k; i++) {
      s += (i + 'a');
      if (s.length() >= n) {
        f = 1;
        break;
      }
      x--;
    }
    if (f) break;
  }
  cout << s;
}
