A permutation p of size n is the sequence p1, p2, ..., pn, consisting of n distinct integers, each of them is from 1 to n (1 ≤ pi ≤ n).

A lucky permutation is such permutation p, that any integer i (1 ≤ i ≤ n) meets this condition ppi = n - i + 1.

You have integer n. Find some lucky permutation p of size n.

Input

The first line contains integer n (1 ≤ n ≤ 105) — the required permutation size.

Output

Print "-1" (without the quotes) if the lucky permutation p of size n doesn't exist.

Otherwise, print n distinct integers p1, p2, ..., pn (1 ≤ pi ≤ n) after a space — the required permutation.

If there are multiple answers, you can print any of them.

Examples

Input

1


Output

1 


Input

2


Output

-1


Input

4


Output

2 4 1 3 


Input

5


Output

2 5 3 1 4 
import java.io.*;
import java.math.BigInteger;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.StringTokenizer;

public class C implements Runnable {

    // leave empty to read from stdin/stdout
    private static final String TASK_NAME_FOR_IO = "";

    // file names
    private static final String FILE_IN = TASK_NAME_FOR_IO + ".in";
    private static final String FILE_OUT = TASK_NAME_FOR_IO + ".out";

    BufferedReader in;
    PrintWriter out;
    StringTokenizer tokenizer = new StringTokenizer("");

    public static void main(String[] args) {
        new Thread(new C()).start();
    }

    boolean good(int n, int[] a) {
        for (int i = 0; i < n; i++)
            if (a[a[i] - 1] != n - i) {
                return false;
            }

        return true;
    }

    private void gen(int pos, int n, int[] used, int[] a, List<int[]> all) {
        if (pos == n) {
            if (good(n, a)) {
                all.add(a.clone());
            }
            return;
        }

        for (int i = 0; i < n; i++)
            if (used[i] == 0) {
                used[i] = 1;
                a[pos] = i + 1;
                gen(pos + 1, n, used, a, all);
                used[i] = 0;
            }
    }

    private void solveNaive(int n) {
        List<int[]> all = new ArrayList<int[]>();
        int[] used = new int[n];
        int[] p = new int[n];
        gen(0, n, used, p, all);

        System.out.println("N = " + n);
        for (int[] a : all) {
            System.out.println(Arrays.toString(a));
        }
    }

    private void solve() throws IOException {

        /*
        for (int n = 5; n <= 12; n++) {
            solveNaive(n);
            solveGood(n);
        }
        */

        int n = nextInt();
        solveGood2(n);
    }

    private void solveGood2(int n) {
        int[] a = new int[n];
        int mod4 = n % 4;

        if (n == 1) {
            out.print("1");
            return;
        }

        if (mod4 > 1) {
            out.print("-1");
            return;
        }

        int l = 0;
        int r = n - 1;
        int lo = 1;
        for (;;) {
            a[l] = n - 1;
            a[l + 1] = lo;
            a[r] = lo + 1;
            a[r - 1] = n;

            n -= 2;
            lo += 2;

            l += 2;
            r -= 2;

            if (l > r) {
                break;
            }

            if (l == r) {
                a[l] = n;
                break;
            }
        }

        for (int v : a) {
            out.print(v);
            out.print(' ');
        }
    }


    private void solveGood(int n) {
        System.out.println("N (GOOD) = " + n);


        int[] a = new int[n];
        int mod4 = n % 4;

        if (n == 1) {
            System.out.println(Arrays.toString(new int[] {1}));
            return;
        }

        if (mod4 > 1) {
            System.out.println(-1);
            return;
        }

        int l = 0;
        int r = n - 1;
        int lo = 1;
        for (;;) {
            a[l] = n - 1;
            a[l + 1] = lo;
            a[r] = lo + 1;
            a[r - 1] = n;

            n -= 2;
            lo += 2;

            l += 2;
            r -= 2;

            if (l > r) {
                break;
            }

            if (l == r) {
                a[l] = n;
                break;
            }
        }

        System.out.println(Arrays.toString(a));
    }

    public void run() {
        long timeStart = System.currentTimeMillis();

        boolean fileIO = TASK_NAME_FOR_IO.length() > 0;
        try {

            if (fileIO) {
                in = new BufferedReader(new FileReader(FILE_IN));
                out = new PrintWriter(new FileWriter(FILE_OUT));
            } else {
                in = new BufferedReader(new InputStreamReader(System.in));
                out = new PrintWriter(new OutputStreamWriter(System.out));
            }

            solve();

            in.close();
            out.close();
        } catch (IOException e) {
            throw new IllegalStateException(e);
        }
        long timeEnd = System.currentTimeMillis();

        if (fileIO) {
            System.out.println("Time spent: " + (timeEnd - timeStart) + " ms");
        }
    }

    private String nextToken() throws IOException {
        while (!tokenizer.hasMoreTokens()) {
            String line = in.readLine();
            if (line == null) {
                return null;
            }
            tokenizer = new StringTokenizer(line);
        }
        return tokenizer.nextToken();
    }

    private int nextInt() throws IOException {
        return Integer.parseInt(nextToken());
    }

    private BigInteger nextBigInt() throws IOException {
        return new BigInteger(nextToken());
    }

    private long nextLong() throws IOException {
        return Long.parseLong(nextToken());
    }

    private double nextDouble() throws IOException {
        return Double.parseDouble(nextToken());
    }

}