Problem: Iahub is very proud of his recent discovery, propagating trees. Right now, he invented a new tree, called xor-tree. After this new revolutionary discovery, he invented a game for kids which uses xor-trees.

The game is played on a tree having n nodes, numbered from 1 to n. Each node i has an initial value initi, which is either 0 or 1. The root of the tree is node 1.

One can perform several (possibly, zero) operations on the tree during the game. The only available type of operation is to pick a node x. Right after someone has picked node x, the value of node x flips, the values of sons of x remain the same, the values of sons of sons of x flips, the values of sons of sons of sons of x remain the same and so on.

The goal of the game is to get each node i to have value goali, which can also be only 0 or 1. You need to reach the goal of the game by using minimum number of operations.

Input

The first line contains an integer n (1 ≤ n ≤ 105). Each of the next n - 1 lines contains two integers ui and vi (1 ≤ ui, vi ≤ n; ui ≠ vi) meaning there is an edge between nodes ui and vi. 

The next line contains n integer numbers, the i-th of them corresponds to initi (initi is either 0 or 1). The following line also contains n integer numbers, the i-th number corresponds to goali (goali is either 0 or 1).

Output

In the first line output an integer number cnt, representing the minimal number of operations you perform. Each of the next cnt lines should contain an integer xi, representing that you pick a node xi.

Examples

Input

10
2 1
3 1
4 2
5 1
6 2
7 5
8 6
9 8
10 5
1 0 1 1 0 1 0 1 0 1
1 0 1 0 0 1 1 1 0 1


Output

2
4
7

Solution (in JAVA):

Solution:

    import java.io.IOException;
    import java.io.InputStream;
    import java.io.PrintWriter;
    import java.util.*;

    public class Solution {


        static final class InputReader {
            private final InputStream stream;
            private final byte[] buf = new byte[1024];
            private int curChar;
            private int numChars;

            public InputReader(InputStream stream) {
                this.stream = stream;
            }

            private int read() throws IOException {
                if (curChar >= numChars) {
                    curChar = 0;
                    numChars = stream.read(buf);
                    if (numChars <= 0) {
                        return -1;
                    }
                }
                return buf[curChar++];
            }

            public final int readInt() throws IOException {
                return (int) readLong();
            }

            public final long readLong() throws IOException {
                int c = read();
                while (isSpaceChar(c)) {
                    c = read();
                    if (c == -1) throw new IOException();
                }
                boolean negative = false;
                if (c == '-') {
                    negative = true;
                    c = read();
                }
                long res = 0;
                do {
                    res *= 10;
                    res += c - '0';
                    c = read();
                } while (!isSpaceChar(c));
                return negative ? -res : res;
            }

            public final int[] readIntArray(int size) throws IOException {
                int[] array = new int[size];
                for (int i = 0; i < size; i++) {
                    array[i] = readInt();
                }
                return array;
            }

            public final long[] readLongArray(int size) throws IOException {
                long[] array = new long[size];
                for (int i = 0; i < size; i++) {
                    array[i] = readLong();
                }
                return array;
            }

            public final String readString() throws IOException {
                int c = read();
                while (isSpaceChar(c)) {
                    c = read();
                }
                StringBuilder res = new StringBuilder();
                do {
                    res.append((char) c);
                    c = read();
                } while (!isSpaceChar(c));
                return res.toString();
            }

            private boolean isSpaceChar(int c) {
                return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
            }
        }

        static long mulmod(long a, long b,
                           long mod) {
            long res = 0; // Initialize result
            a = a % mod;
            while (b > 0) {
                // If b is odd, add 'a' to result
                if (b % 2 == 1) {
                    res = (res + a) % mod;
                }

                // Multiply 'a' with 2
                a = (a * 2) % mod;

                // Divide b by 2
                b /= 2;
            }

            // Return result
            return res % mod;
        }

        static long pow(long a, long b, long MOD) {
            long x = 1, y = a;
            while (b > 0) {
                if (b % 2 == 1) {
                    x = (x * y);
                    if (x > MOD) x %= MOD;
                }
                y = (y * y);
                if (y > MOD) y %= MOD;
                b /= 2;
            }
            return x;
        }

        static long[] f = new long[100001];

        static long InverseEuler(long n, long MOD) {
            return pow(n, MOD - 2, MOD);
        }

        static long C(int n, int r, long MOD) {

            return (f[n] * ((InverseEuler(f[r], MOD) * InverseEuler(f[n - r], MOD)) % MOD)) % MOD;
        }

        public static class SegmentTree {
            long[] tree;
            long[] lazy;
            int n;

            public SegmentTree(long[] arr) {
                n = arr.length;
                tree = new long[arr.length * 5];
                lazy = new long[arr.length * 5];
                build(arr, 0, arr.length - 1, 0);
            }

            private void build(long[] arr, int s, int e, int pos) {
                if (s == e) {
                    tree[pos] = arr[s];
                    return;
                }
                int m = (s + e) / 2;

                build(arr, s, m, 2 * pos + 1);
                build(arr, m + 1, e, 2 * pos + 2);

                tree[pos] = Math.max(tree[2 * pos + 1], tree[2 * pos + 2]);
            }

            public void update(int s, int e, long val) {
                updateUtil(s, e, val, 0, n - 1, 0);
            }

            public long get(int s, int e) {
                return getUtil(s, e, 0, n - 1, 0);
            }

            private long getUtil(int gs, int ge, int s, int e, int pos) {
                if (s > e || s > ge || e < gs) return Long.MIN_VALUE;
                if (lazy[pos] != 0) {
                    tree[pos] += lazy[pos];
                    if (s != e) {
                        lazy[2 * pos + 1] += lazy[pos];
                        lazy[2 * pos + 2] += lazy[pos];
                    }
                    lazy[pos] = 0;
                }
                if (s >= gs && e <= ge) {
                    return tree[pos];
                }
                int m = (s + e) / 2;
                return Math.max(getUtil(gs, ge, s, m, 2 * pos + 1), getUtil(gs, ge, m + 1, e, 2 * pos + 2));
            }

            private void updateUtil(int us, int ue, long val, int s, int e, int pos) {
                if (s > e || s > ue || e < us) return;

                if (lazy[pos] != 0) {
                    tree[pos] += lazy[pos];
                    if (s != e) {
                        lazy[2 * pos + 1] += lazy[pos];
                        lazy[2 * pos + 2] += lazy[pos];
                    }
                    lazy[pos] = 0;
                }

                if (s >= us && e <= ue) {
                    tree[pos] += val;
                    if (s != e) {
                        lazy[2 * pos + 1] += val;
                        lazy[2 * pos + 2] += val;
                    }
                    return;
                }

                int m = (s + e) / 2;
                updateUtil(us, ue, val, s, m, 2 * pos + 1);
                updateUtil(us, ue, val, m + 1, e, 2 * pos + 2);

                tree[pos] = Math.max(tree[2 * pos + 1], tree[2 * pos + 2]);
            }


        }


        static int[] h = {0, 0, -1, 1};
        static int[] v = {1, -1, 0, 0};

        public static class Pair {
            public int type, x, y, pos;

            public Pair(int type, int x, int y, int pos) {
                this.type = type;
                this.x = x;
                this.y = y;
                this.pos = pos;
            }
        }
        public static class Elements {
            public long w, t;
        }
        public static void main(String[] args) throws Exception {
            //https://i...content-available-to-author-only...e.com/ebRGa6
            InputReader in = new InputReader(System.in);
            PrintWriter w = new PrintWriter(System.out);
            int n = in.readInt();
            List<List<Integer>> g = new ArrayList<>();
            List<Integer> answers = new ArrayList<>();
            int[] old = new int[n+1];
            int[] changed = new int[n+1];
            int answer = 0;
            for (int cx = 0; cx <= n; ++cx) {
                g.add(new ArrayList<>());
            }
            for (int cx = 1; cx < n; ++cx) {
                int f = in.readInt();
                int t = in.readInt();
                g.get(f).add(t);
                g.get(t).add(f);
            }
            for (int cx = 1; cx <= n; ++cx) {
                old[cx] = in.readInt();
            }
            for (int cx = 1; cx <= n; ++cx) {
                changed[cx] = in.readInt();
            }
            int[] visited = new int[n+1];
            Arrays.fill(visited, -1);
            Queue<Integer> q = new LinkedList<>();
            q.add(1);
            visited[1] = 0;
            while (q.size() != 0) {
                Integer node = q.remove();
                int current = 0;
                if (visited[node] == 2 || visited[node] == 3) {
                    if (old[node] == changed[node]) {
                        answer++;
                        answers.add(node);
                    } else {
                        current = 1;
                    }
                } else {
                    if (old[node] != changed[node]) {
                        answer++;
                        answers.add(node);
                        current = 1;
                    }
                }
                for (int i=0; i < g.get(node).size(); ++i) {
                    int nodeToBe = g.get(node).get(i);
                    if (visited[nodeToBe] == -1) {
                        q.add(nodeToBe);
                        visited[nodeToBe] = current + ((visited[node] & 1) << 1);
                    }
                }
            }
            System.out.println(answer);
            for (int i=0; i <answer; ++i) {
                System.out.println(answers.get(i));
            }

        }

        static int gcd(int a, int b) {

            while (b != 0) {
                int t = a;
                a = b;
                b = t % b;
            }
            return a;
        }


    }