#include <bits/stdc++.h>
using namespace std;
const long long oo = 1e18;
const int N = 2 * 1e5 + 5;
const double eps = 1e-5;
bool vis[N] = {0};
vector<int> ans;
vector<vector<int>> g;
int goal[N], init[N];
void dfs(int u, int even, int odd, int lvl) {
  vis[u] = 1;
  if (lvl % 2 && odd % 2 || !(lvl % 2) && even % 2) init[u] ^= 1;
  if (init[u] != goal[u]) {
    ans.push_back(u);
    if (lvl % 2 == 0) {
      for (int i = 0; i < g[u].size(); i++)
        if (!vis[g[u][i]]) dfs(g[u][i], even + 1, odd, lvl + 1);
    } else {
      for (int i = 0; i < g[u].size(); i++)
        if (!vis[g[u][i]]) dfs(g[u][i], even, odd + 1, lvl + 1);
    }
  } else
    for (int i = 0; i < g[u].size(); i++)
      if (!vis[g[u][i]]) dfs(g[u][i], even, odd, lvl + 1);
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  g.resize(n + 1);
  for (int i = 0; i < n - 1; i++) {
    int a, b;
    cin >> a >> b;
    g[a].push_back(b);
    g[b].push_back(a);
  }
  for (int i = 1; i <= n; i++) cin >> init[i];
  for (int i = 1; i <= n; i++) cin >> goal[i];
  dfs(1, 0, 0, 1);
  cout << ans.size() << endl;
  for (auto it : ans) cout << it << endl;
}
