#include <bits/stdc++.h>
using namespace std;
vector<int> graph[10001 + 1];
bool vis[10001 + 4];
map<int, int> color, curcol;
int cnt = 0;
void dfs(int start, int mycol) {
  for (int j = 0; j < graph[start].size(); j++) {
    int cux = graph[start][j];
    if (mycol != color[cux]) cnt++;
  }
}
int main() {
  int n, x;
  scanf("%d", &n);
  for (int i = (int)2; i <= n; i++) {
    scanf("%d", &x);
    graph[x].push_back(i);
  }
  for (int i = (int)1; i <= n; i++) {
    scanf("%d", &x);
    color[i] = x;
    curcol[i] = 0;
  }
  for (int i = 1; i <= n; i++) {
    dfs(i, color[i]);
  }
  cnt++;
  printf("%d", cnt);
}
