#include <bits/stdc++.h>
using namespace std;
const double PI = acos(-1.0);
const double EPS = 1e-9;
const double INF = 2e10;
const long long OO = (1LL << 60);
int dx[] = {1, -1, 0, 0, 1, 1, -1, -1};
int dy[] = {0, 0, -1, 1, -1, 1, -1, 1};
bool vis[100002];
int init[100002];
int goal[100002];
vector<int> adj[100002];
int ans = 0;
vector<int> idx;
void dfs(int u, int odd, int even, int i) {
  if (vis[u]) {
    return;
  }
  vis[u] = true;
  for (auto it : adj[u]) {
    if (i % 2 == 0) {
      if ((even % 2 == 0 && init[it] != goal[it]) ||
          (even % 2 != 0 && init[it] == goal[it])) {
        dfs(it, odd, even + 1, i + 1);
        idx.push_back(it);
      } else {
        dfs(it, odd, even, i + 1);
      }
    } else if (i % 2 != 0) {
      if ((odd % 2 == 0 && init[it] != goal[it]) ||
          (odd % 2 != 0 && init[it] == goal[it])) {
        dfs(it, odd + 1, even, i + 1);
        idx.push_back(it);
      } else {
        dfs(it, odd, even, i + 1);
      }
    }
  }
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(NULL), cout.tie(NULL);
  ios::sync_with_stdio(false), cin.tie(0);
  int n;
  cin >> n;
  for (int i = 0; i < n - 1; ++i) {
    int x, y;
    cin >> x >> y;
    adj[y].push_back(x);
    adj[x].push_back(y);
  }
  for (int i = 1; i <= n; ++i) {
    vis[i] = false;
    cin >> init[i];
  }
  for (int i = 1; i <= n; ++i) {
    cin >> goal[i];
  }
  if (init[1] != goal[1]) {
    idx.push_back(1);
    dfs(1, 0, 1, 1);
  } else {
    dfs(1, 0, 0, 1);
  }
  cout << ((int)(idx).size()) << endl;
  for (auto it : idx) {
    cout << it << endl;
  }
  return 0;
}
