import sys def input(): return sys.stdin.readline().strip() def mapint(): return list(map(int, input().split())) sys.setrecursionlimit(10**9) N = int(input()) if N==1: print(1) elif N==3 or N==5: print(-1) else: ans = [2, 4, *list(range(8, N, 2)), 6, 3] print(*ans[:-(-N//2)])