#include <bits/stdc++.h>
using namespace std;
class Graph {
  int V;
  list<int> *adj;

 public:
  Graph(int V);
  void addEdge(int v, int w);
  void BFS(int s);
};
Graph::Graph(int V) {
  this->V = V;
  adj = new list<int>[V];
}
void Graph::addEdge(int v, int w) { adj[v].push_back(w); }
void Graph::BFS(int s) {
  bool *visited = new bool[V];
  for (int i = 0; i < V; i++) visited[i] = false;
  list<int> queue;
  visited[s] = true;
  queue.push_back(s);
  list<int>::iterator i;
  while (!queue.empty()) {
    s = queue.front();
    cout << s << " ";
    queue.pop_front();
    for (i = adj[s].begin(); i != adj[s].end(); ++i) {
      if (!visited[*i]) {
        visited[*i] = true;
        queue.push_back(*i);
      }
    }
  }
}
int main() {
  int n;
  cin >> n;
  int arr[n + 2];
  memset(arr, 0, sizeof(arr));
  vector<int> g[n + 2];
  for (int i = 1; i <= n - 1; ++i) {
    int temp;
    cin >> temp;
    g[i + 1].push_back(temp);
    g[temp].push_back(i + 1);
  }
  for (int j = 1; j <= n; ++j) {
    cin >> arr[j];
  }
  bool visit[n + 2];
  memset(visit, 0, sizeof(visit));
  visit[1] = true;
  list<int> queue;
  queue.push_back(1);
  vector<int>::iterator i;
  int ans = 1;
  int color;
  int currcolor[n + 2];
  memset(currcolor, 0, sizeof(currcolor));
  currcolor[1] = arr[1];
  while (!queue.empty()) {
    int s = queue.front();
    queue.pop_front();
    color = currcolor[s];
    if (color != arr[s]) {
      currcolor[s] = arr[s];
      color = currcolor[s];
      ans++;
    }
    for (i = g[s].begin(); i != g[s].end(); ++i) {
      if (!visit[*i]) {
        visit[*i] = true;
        currcolor[*i] = color;
        queue.push_back(*i);
      }
    }
  }
  cout << ans << endl;
  return 0;
}
