#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, k;
  while (scanf("%d %d", &n, &k) != EOF) {
    if (k > n || (n > 1 && k == 1)) {
      printf("-1\n");
      continue;
    }
    if (n == 1 && k == 1) {
      printf("a\n");
      continue;
    }
    for (int i = 1; i <= n - k + 2; ++i) {
      if (i & 1)
        printf("a");
      else
        printf("b");
    }
    for (int i = 0; i < k - 2; ++i) printf("%c", 'c' + i);
    printf("\n");
  }
  return 0;
}
