#include <bits/stdc++.h>
using namespace std;
bool reqval[100000];
bool visit[100000];
bool val[100000];
vector<long> changed;
vector<long> adj[100000];
void DFS(long ind, bool flip0, bool flip1, long level) {
  if (visit[ind]) return;
  if ((level % 2 && flip1) || (level % 2 == 0 && flip0)) {
    val[ind] = !val[ind];
  }
  visit[ind] = true;
  if (val[ind] != reqval[ind]) {
    changed.push_back(ind + 1);
    if (level % 2)
      flip1 = !flip1;
    else
      flip0 = !flip0;
  }
  for (long i = 0; i < adj[ind].size(); i++) {
    DFS(adj[ind][i], flip0, flip1, level + 1);
  }
}
int main() {
  long n;
  cin >> n;
  long u, v;
  for (long i = 0; i < n - 1; i++) {
    cin >> u >> v;
    u--, v--;
    adj[u].push_back(v);
    adj[v].push_back(u);
  }
  for (long i = 0; i < n; i++) {
    cin >> val[i];
    visit[i] = 0;
  }
  for (long i = 0; i < n; i++) {
    cin >> reqval[i];
  }
  DFS(0, 0, 0, 0);
  cout << changed.size() << endl;
  for (long i = 0; i < changed.size(); i++) {
    cout << changed[i] << endl;
  }
  return 0;
}
