#include <bits/stdc++.h>
using namespace std;
vector<int> p;
vector<int> colors;
int n;
int recurse(const int& current_vertex, const int& parent_vertex) {
  int num_adj = 0;
  for (int i = 0; i < n; i++) {
    if (p[i] == current_vertex) {
      num_adj++;
    }
  }
  if (num_adj == 0) {
    return 0;
  }
  int result = 0;
  for (int i = 0; i < n; i++) {
    if (i != parent_vertex && p[i] == current_vertex) {
      result += recurse(i, current_vertex);
      if (colors[i] != colors[current_vertex]) {
        result++;
      }
    }
    if (p[current_vertex] != parent_vertex) {
      result += recurse(p[current_vertex], current_vertex);
      if (colors[p[current_vertex]] != colors[current_vertex]) {
        result++;
      }
    }
  }
  return result;
}
int main() {
  cin >> n;
  p = vector<int>(n);
  p[0] = 0;
  for (int i = 1; i < n; i++) {
    int a;
    cin >> a;
    a--;
    p[i] = a;
  }
  colors = vector<int>(n);
  for (int i = 0; i < n; i++) {
    cin >> colors[i];
  }
  int result = recurse(0, 0) + 1;
  cout << result << endl;
  return 0;
}
