Takahashi has an ability to generate a tree using a permutation (p_1,p_2,...,p_n) of (1,2,...,n), in the following process:

First, prepare Vertex 1, Vertex 2, ..., Vertex N. For each i=1,2,...,n, perform the following operation:

* If p_i = 1, do nothing.
* If p_i \neq 1, let j' be the largest j such that p_j < p_i. Span an edge between Vertex i and Vertex j'.



Takahashi is trying to make his favorite tree with this ability. His favorite tree has n vertices from Vertex 1 through Vertex n, and its i-th edge connects Vertex v_i and w_i. Determine if he can make a tree isomorphic to his favorite tree by using a proper permutation. If he can do so, find the lexicographically smallest such permutation.

Constraints

* 2 \leq n \leq 10^5
* 1 \leq v_i, w_i \leq n
* The given graph is a tree.

Input

Input is given from Standard Input in the following format:


n
v_1 w_1
v_2 w_2
:
v_{n-1} w_{n-1}


Output

If there is no permutation that can generate a tree isomorphic to Takahashi's favorite tree, print `-1`. If it exists, print the lexicographically smallest such permutation, with spaces in between.

Examples

Input

6
1 2
1 3
1 4
1 5
5 6


Output

1 2 4 5 3 6


Input

6
1 2
2 3
3 4
1 5
5 6


Output

1 2 3 4 5 6


Input

15
1 2
1 3
2 4
2 5
3 6
3 7
4 8
4 9
5 10
5 11
6 12
6 13
7 14
7 15


Output

-1
import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.stream.IntStream;
import java.io.PrintStream;
import java.util.Arrays;
import java.io.IOException;
import java.util.OptionalInt;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.List;
import java.util.StringTokenizer;
import java.io.BufferedReader;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        FastScanner in = new FastScanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskF solver = new TaskF();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskF {
        List<Integer>[] tree;
        boolean[] leaf;
        List<Integer> result = new ArrayList<>();

        public void solve(int testNumber, FastScanner in, PrintWriter out) {
            int n = in.nextInt();
            tree = new List[n];
            for (int i = 0; i < n; i++) {
                tree[i] = new ArrayList<>();
            }
            for (int i = 0; i < n - 1; i++) {
                int from = in.nextInt() - 1, to = in.nextInt() - 1;
                tree[from].add(to);
                tree[to].add(from);
            }

            leaf = new boolean[n];
            for (int i = 0; i < n; i++) {
                leaf[i] = tree[i].size() == 1;
            }
            int[] deg = new int[n];
            for (int i = 0; i < n; i++) {
                if (!leaf[i]) {
                    for (int j : tree[i]) {
                        if (!leaf[j]) {
                            deg[i]++;
                        }
                    }
                }
            }
            int max = Arrays.stream(deg).max().getAsInt();
            if (max > 2) {
                out.println(-1);
                return;
            }

            int[] result = new int[n];
            for (int i = n - 1; i >= 0; i--) {
                result[i] = n - 1 - i;
            }
            if (max == 0) {
                for (int i = 0; i < n; i++) {
                    if (leaf[i]) {
                        result = get(i);
                        break;
                    }
                }

            } else {
                for (int i = 0; i < n; i++) {
                    if (!leaf[i] && deg[i] == 1) {
                        for (int j : tree[i]) {
                            if (leaf[j]) {
                                int[] newResult = get(j);
                                for (int t = 0; t < n; t++) {
                                    if (result[t] < newResult[t]) {
                                        break;
                                    } else if (result[t] > newResult[t]) {
                                        result = newResult;
                                        break;
                                    }
                                }
                                break;
                            }
                        }
                    }
                }
            }

            for (int i : result) {
                out.print((i + 1) + " ");
            }
            out.println();
        }

        int[] get(int start) {
            int n = tree.length;
            result = new ArrayList<>();
            go(start, -1, 0);
            int[] ret = new int[n];
            System.err.println(result.toString());
            for (int i = 0; i < n; i++) {
                ret[result.get(i)] = i;
            }
            return ret;
        }

        private void go(int i, int p, int startId) {
            int deg = 0;
            for (int t : tree[i]) {
                if (t != p) {
                    deg++;
                }
            }
            int ourId = -1;
            if (deg == 0) {
                ourId = startId;
                result.add(startId);
            } else {
                ourId = startId + deg - 1;
                result.add(startId + deg - 1);
            }
            for (int t : tree[i]) {
                if (t != p) {
                    if (leaf[t]) {
                        if (startId == ourId) {
                            startId++;
                        }
                        go(t, i, startId);
                        startId++;
                    }
                }
            }
            for (int t : tree[i]) {
                if (t != p) {
                    if (!leaf[t]) {
                        if (startId == ourId) {
                            startId++;
                        }
                        go(t, i, startId);
                        startId++;
                    }
                }
            }
        }

    }

    static class FastScanner {
        BufferedReader br;
        StringTokenizer st;

        public FastScanner(InputStream in) {
            br = new BufferedReader(new InputStreamReader(in));
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }

        public String next() {
            while (st == null || !st.hasMoreElements()) {
                String line = null;
                try {
                    line = br.readLine();
                } catch (IOException e) {
                }
                st = new StringTokenizer(line);
            }
            return st.nextToken();
        }

    }
}

