#include <bits/stdc++.h>
using namespace std;
vector<long long> adj[1000005];
long long vis[1000005];
long long b[1000005];
long long color = 1;
void BFS(long long s) {
  std::queue<long long> q;
  q.push(s);
  vis[s] = 1;
  while (!q.empty()) {
    long long curr = q.front();
    q.pop();
    for (long long child : adj[curr]) {
      if (vis[child]) {
        continue;
      }
      if (b[child] != b[curr]) {
        color++;
      }
      vis[child] = 1;
      q.push(child);
    }
  }
}
signed main() {
  long long n;
  cin >> n;
  long long a[n + 1];
  for (long long i = 2; i <= n; i++) {
    cin >> a[i];
    adj[i].push_back(a[i]);
    adj[a[i]].push_back(i);
  }
  for (long long i = 1; i <= n; i++) {
    cin >> b[i];
  }
  BFS(1);
  cout << color;
  return 0;
}
