#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, k;
  cin >> n >> k;
  string s;
  if (k > n) {
    cout << -1;
    return 0;
  }
  if (k == 1 && n == 1) {
    cout << 'a';
    return 0;
  }
  if (k == 1) {
    cout << -1;
    return 0;
  }
  for (int i = 1; i <= n; i++) {
    if (i % 2 == 1)
      s += 'a';
    else
      s += 'b';
  }
  int y = n - k + 2;
  char c = 'c';
  for (int i = y; i < n; i++) {
    s[i] = c;
    c++;
  }
  cout << s;
  return 0;
}
