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