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