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