#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long int i, j, k, z, x = 1e18, y = -1, sum = 1e18, p, q, l, T, m,
                            ans = 0;
  long long int n;
  double xx, yy;
  bool f = false;
  string s;
  cin >> n >> k;
  if (k == 1) {
    if (n == 1)
      cout << 'a';
    else
      cout << "-1";
  } else if (n >= k) {
    for (i = 1; i <= n - (k - 2); i++) {
      if (i % 2 == 1)
        cout << 'a';
      else
        cout << 'b';
    }
    char c = 'c';
    for (i = 1; i <= k - 2; i++) cout << c++;
  } else
    cout << -1;
  return 0;
}
