#include <bits/stdc++.h>
using namespace std;
constexpr int MAX = 1e5 + 10;
vector<int> adj[MAX];
bool visited[MAX];
bool bits[MAX], cpybits[MAX];
bool targetbits[MAX];
int parent[MAX];
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int n;
  cin >> n;
  int u, v;
  for (int i = 0; i < n - 1; ++i) {
    cin >> u >> v;
    adj[u].push_back(v);
    adj[v].push_back(u);
  }
  for (int i = 1; i <= n; ++i) cin >> bits[i];
  for (int i = 1; i <= n; ++i) cin >> targetbits[i];
  memcpy(cpybits, bits, sizeof(bits));
  queue<int> q;
  q.push(1);
  int result = 0;
  vector<int> changes;
  parent[1] = 0;
  while (q.size() != 0) {
    int v = q.front();
    q.pop();
    visited[v] = true;
    vector<int>& neighbors = adj[v];
    if (bits[parent[parent[v]]] != cpybits[parent[parent[v]]]) bits[v] ^= 1;
    if (bits[v] != targetbits[v]) {
      result++;
      bits[v] ^= 1;
      changes.push_back(v);
    }
    for (int neighbor : neighbors) {
      if (visited[neighbor]) continue;
      q.push(neighbor);
      parent[neighbor] = v;
    }
  }
  cout << result << "\n";
  for (int x : changes) cout << x << "\n";
  return 0;
}
