#include <bits/stdc++.h>
using namespace std;
vector<int> note[100005];
int num[100005], num1[100005], n;
bool charge1[100005], charge2[100005];
vector<int> ans;
void solve(int a, int changel, int changer) {
  if (charge1[a]) return;
  num[a] = (num[a] + changel) % 2;
  charge1[a] = true;
  if (num[a] != num1[a]) {
    ans.push_back(a);
    changel = (changel + 1) % 2;
  }
  for (int i = 0; i < note[a].size(); i++) {
    solve(note[a][i], changer, changel);
  }
}
int main() {
  scanf("%d", &n);
  int t, y;
  for (int i = 0; i < n - 1; i++) {
    scanf("%d%d", &t, &y);
    note[t].push_back(y);
    note[y].push_back(t);
  }
  for (int i = 1; i <= n; i++) {
    scanf("%d", &num[i]);
  }
  for (int i = 1; i <= n; i++) {
    scanf("%d", &num1[i]);
  }
  solve(1, 0, 0);
  printf("%d\n", ans.size());
  for (int i = 0; i < ans.size(); i++) {
    printf("%d\n", ans[i]);
  }
  return 0;
}
