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