N, K = map(int, input().split()) if N % K == 0: print(*[1 for _ in range(N // K)],*[2 for _ in range(N - N // K)]) else: print(-1)