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