#include <bits/stdc++.h>
using namespace std;
map<int, vector<int> > graph;
int n, u, ans = 0, color[10007];
int main() {
  scanf("%d", &n);
  for (int i = 2; i <= n; i++) {
    scanf("%d", &u);
    graph[u].push_back(i);
  }
  for (int i = 1; i <= n; i++) scanf("%d", &color[i]);
  function<void(int, int)> dfs = [&](int u, int v) {
    if (color[u] != v) ans++;
    for (auto i : graph[u]) dfs(i, color[u]);
  };
  dfs(1, 0);
  printf("%d", ans);
}
