#include <bits/stdc++.h>
using namespace std;
int main(int argc, char const *argv[]) {
  int n, k;
  cin >> n >> k;
  if (k > n || (n > 1 && k == 1)) {
    cout << -1 << endl;
    return 0;
  }
  if (n == 1) {
    cout << "a" << endl;
    return 0;
  }
  for (int i = 0; i < n - k; i += 2) {
    cout << "ab";
  }
  cout << "a";
  if ((n - k) % 2 == 0) cout << "b";
  for (int i = 0; i < k - 2; i++) cout << char('c' + i);
  cout << endl;
  return 0;
}
