#include <bits/stdc++.h>
unsigned long long mulmod(unsigned long long a, unsigned long long b,
                          unsigned long long c) {
  unsigned long long x = 0, y = a % c;
  while (b > 0) {
    if (b % 2 == 1) {
      x = (x + y) % c;
    }
    y = (y * 2) % c;
    b /= 2;
  }
  return x % c;
}
unsigned long long pow(unsigned long long a, unsigned long long b,
                       unsigned long long c) {
  unsigned long long x = 1, y = a;
  while (b > 0) {
    if (b & 1) x = mulmod(x, y, c);
    y = mulmod(y, y, c);
    b >>= 1;
  }
  return x;
}
using namespace std;
int main() {
  int n, k;
  cin >> n >> k;
  if (n < k || (n != 1 && k == 1)) {
    cout << "-1\n";
    return 0;
  }
  if (n == 1 && k == 1) {
    cout << "a\n";
    return 0;
  }
  int ab = n - k + 2;
  char ch = 'a';
  for (int i = 0; i < ab; i++) {
    cout << ch;
    if (ch == 'a')
      ch = 'b';
    else
      ch = 'a';
  }
  ch = 'c';
  for (int i = 0; i < k - 2; i++) {
    cout << ch;
    ch++;
  }
  cout << endl;
  return 0;
}
