#include<stdio.h>

int a[100100];

int main() {

int n,i,k;

while(scanf("%d%d",&n,&k)!=EOF) {

if(k==n) {

printf("-1\n");

continue;

}

for(i=2;i<=k+1;i++)

a[i]=i;

for(i=k+3;i<=n;i+=2) {

a[i]=i-1;

a[i-1]=i;

}

if(i-1==n) {

a[1]=n;

a[n]=1;

}

else

a[1]=1;

printf("%d",a[1]);

for(i=2;i<=n;i++)

        printf(" %d",a[i]);

printf("\n");

}

return 0;

}

05-28 21:07