#include <bits/stdc++.h>
#pragma warning(disable : 4786)
#pragma comment(linker, "/STACK:16777216")
using namespace std;
const double EPS = 1e-11;
const int INF = 2e30;
const double PI = 2 * acos(0.0);
int MAX(int a, int b) { return a > b ? a : b; }
long long MIN(long long a, long long b) { return a < b ? a : b; }
void SWAP(int &a, int &b) {
  int t = a;
  a = b;
  b = t;
}
int GCD(int a, int b) {
  while (b) {
    b ^= a ^= b ^= a %= b;
  }
  return a;
}
bool isPrime[100005];
int primeCount[100005];
void seive() {
  int i, j;
  for (i = 0; i < 100005; i++) {
    isPrime[i] = true;
    primeCount[i] = 0;
  }
  isPrime[0] = false;
  isPrime[1] = false;
  for (i = 2; i < 100005; i++) {
    if (isPrime[i] == true) {
      for (j = 2 * i; j < 100005; j += i) {
        isPrime[j] = false;
      }
    }
  }
  for (i = 0, j = 0; i < 100005; i++) {
    if (isPrime[i] == true) j++;
    primeCount[i] = j;
  }
}
int main() {
  seive();
  int i, j, n, k, arr[100005];
  scanf("%d %d", &n, &k);
  if (n == k) {
    printf("-1\n");
  } else {
    for (i = 2; i <= n - k; i++) {
      if (i != 2) printf(" ");
      printf("%d", i);
    }
    printf(" 1");
    for (; i <= n; i++) printf(" %d", i);
    printf("\n");
  }
  return 0;
}
