#include <bits/stdc++.h>
using namespace std;
int n, a[10010], fa[10100];
int main() {
  int x, s = 0;
  cin >> n;
  for (int i = 2; i <= n; ++i) cin >> x, fa[i] = x;
  for (int i = 1; i <= n; ++i) cin >> a[i], a[i] != a[fa[i]] ? ++s : 0;
  cout << s;
}
