#include <bits/stdc++.h>
using namespace std;
const long long M = 1e6 + 10, MOD = 1000000007;
vector<int> Edge[200005];
int nokol[200022], dist[200002], original[200002];
int dp[200002][5];
bool vis[200020];
vector<int> v;
void goforbfs() {
  queue<int> q;
  q.push(1);
  if (nokol[1] != original[1]) {
    dp[1][0]++;
    v.push_back(1);
  }
  dist[1] = 0;
  while (q.size()) {
    int x = q.front();
    vis[x] = 1;
    q.pop();
    for (int i = 0; i < Edge[x].size(); i++) {
      int y = Edge[x][i];
      if (!vis[y]) {
        dist[y] = dist[x] + 1;
        dp[y][1] = dp[x][1];
        dp[y][0] = dp[x][0];
        q.push(y);
        if (dist[y] % 2) {
          if (dp[y][1] % 2) {
            (nokol[y] == 1) ? nokol[y] = 0 : nokol[y] = 1;
          }
          if (nokol[y] != original[y]) {
            v.push_back(y);
            dp[y][1]++;
          }
        } else {
          if (dp[y][0] % 2) {
            (nokol[y] == 1) ? nokol[y] = 0 : nokol[y] = 1;
          }
          if (nokol[y] != original[y]) {
            v.push_back(y);
            dp[y][0]++;
          }
        }
      }
    }
  }
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int n;
  cin >> n;
  for (int i = 1; i < n; i++) {
    int x, y;
    cin >> x >> y;
    Edge[x].push_back(y);
    Edge[y].push_back(x);
  }
  for (int i = 1; i <= n; i++) cin >> nokol[i];
  for (int i = 1; i <= n; i++) cin >> original[i];
  goforbfs();
  cout << (int)v.size() << "\n";
  for (auto it : v) cout << it << "\n";
  return 0;
}
