#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, k, i, j, p, x;
  cin >> n >> k;
  p = n;
  n = n - k + 2;
  if (k > p || k == 1 && p != 1)
    cout << "-1\n";
  else if (k == p) {
    for (i = 0; i < p; i++) cout << char(i + 97);
    cout << "\n";
  } else {
    if (n % 2 == 0) {
      for (i = 0; i < n / 2; i++) cout << "ab";
      for (i = 0; i < k - 2; i++) cout << char(i + 99);
      cout << "\n";
    } else {
      for (i = 0; i < n / 2; i++) cout << "ab";
      cout << "a";
      x = n / 2;
      x = 2 * x;
      x++;
      for (i = 0; i < p - x; i++) cout << char(i + 99);
      cout << "\n";
    }
  }
  return 0;
}
