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