#include <bits/stdc++.h>
using namespace std;
struct Tree {
  int color;
  Tree* parent;
  Tree() { parent = NULL; }
  Tree(Tree* t) { parent = t; }
};
int main() {
  vector<Tree*> v;
  v.push_back(new Tree());
  int ile;
  cin >> ile;
  for (int i = 1; i < ile; i++) {
    int p;
    cin >> p;
    v.push_back(new Tree(v[p - 1]));
  }
  for (int i = 0; i < ile; i++) {
    int c;
    cin >> c;
    v[i]->color = c;
    for (Tree* t : v) {
      if (t->parent == v[i]) t->color = c;
    }
  }
  ile = 1;
  for (Tree* t : v) {
    if (t->parent == NULL) continue;
    if (t->color != t->parent->color) ile++;
  }
  cout << ile;
  return 0;
}
