#include <bits/stdc++.h>
using namespace std;
const int mod = 1000000007;
vector<vector<int>> ed = {{1, 0}, {0, 1}, {-1, 0}, {0, -1}};
bool myComp(int i, int j) { return i > j; }
int main() {
  int n;
  cin >> n;
  vector<vector<int>> adj(n);
  vector<int> col(n), curcol(n, 0);
  for (int i = 0; i < n - 1; ++i) {
    int a;
    cin >> a;
    adj[a - 1].push_back(i + 1);
  }
  for (int i = 0; i < n; ++i) {
    cin >> col[i];
  }
  int ans = 0;
  for (int i = 0; i < n; ++i) {
    if (curcol[i] == col[i]) continue;
    ++ans;
    stack<int> s;
    s.push(i);
    while (!s.empty()) {
      int &cur = s.top();
      s.pop();
      int nNeigh = adj[cur].size();
      vector<int> &neigh = adj[cur];
      for (int j = 0; j < nNeigh; ++j) {
        int &next = neigh[j];
        curcol[next] = col[i];
        s.push(next);
      }
    }
  }
  cout << ans << endl;
  return 0;
}
