#include <bits/stdc++.h>
using namespace std;
int main() {
  int N, K;
  cin >> N >> K;
  if (N == 1 && K == 1)
    cout << 'a';
  else if (N < K || K == 1)
    cout << -1;
  else {
    for (int i = 1; i <= N - K + 2; i++) cout << ((i & 1) ? 'a' : 'b');
    for (int i = N - K + 3; i <= N; i++)
      cout << char('a' + i - (N - K + 3) + 2);
  }
  return 0;
}
