#include <bits/stdc++.h>
using namespace std;
using i64 = long long;
#define rep(i,s,e) for(i64 (i) = (s);(i) < (e);(i)++)
#define all(x) x.begin(),x.end()
#define let auto const

template<typename... Types>
struct dynarr: std::vector<Types...> {
  using std::vector<Types...>::vector;
  using size_type = typename std::vector<Types...>::size_type;
  auto&& operator[](size_type i) { return this->at(i); }
  auto&& operator[](size_type i) const { return this->at(i); }
};
struct eulartour_subtree {
  vector<vector<i64>> G;
  vector<i64> tour;
  vector<i64> L, R;
  eulartour_subtree(i64 n): G(n), L(n), R(n) {}
  void add_edge(i64 u, i64 v) {
    G[u].push_back(v);
    G[v].push_back(u);
  }

  void dfs(i64 v, i64 f) {
    tour.push_back(v);
    L[v] = tour.size() - 1;
    for(auto to: G[v]) {
      if(to == f) continue;
      dfs(to, v);
      tour.push_back(v);
    }
    R[v] = tour.size() - 1;
  }

  i64 start_tour(i64 r) {
    dfs(r, -1);
    return tour.size();
  }

  pair<i64, i64> subtree_range(i64 v) {
    return pair<i64, i64>(L[v], R[v]);
  }

  i64 update_point(i64 v) {
    return L[v];
  }
};

#include <bits/stdc++.h>
using namespace std;
using i64 = long long;

struct lazy_segment_tree {
  using T = pair<i64, i64>;
  using L = i64;
  T t_ide() { return {0ll, 0ll}; }
  L l_ide() { return 0; }
  T ope(const T& a, const T& b) { return T(a.first + b.first, a.second + b.second); }
  L lazy_ope(const L& a, const L& b) { return a ^ b; }
  T effect(const T& t, const L& l, const i64 len) {
    if(l == 0) return t;
    else return T(t.second, t.first);
  }

  i64 n;
  vector<T> node;
  vector<L> lazy;
  vector<bool> flag;

  /* create lazy_segment_tree for sequence [t_ide; sz]A */
  lazy_segment_tree(vector<T> init) {
    n = 1;
    i64 sz = init.size();
    while(n < sz) n *= 2;
    node.assign(n * 2, t_ide());
    for(int i = 0; i < init.size();i++) node[i + n - 1] = init[i];
    for(int i = n - 2; i >= 0;i--) node[i] = ope(node[i * 2 + 1], node[i * 2 + 2]);
    lazy.assign(n * 2, l_ide());
    flag.assign(n * 2, false);
  }
  

  void eval(i64 l, i64 r, i64 k) {
    if(flag[k]) {
      node[k] = effect(node[k], lazy[k], r - l);
      
      if(r - l > 1) {
        lazy[k * 2 + 1] = lazy_ope(lazy[k * 2 + 1], lazy[k]);
        flag[k * 2 + 1] = true;
        lazy[k * 2 + 2] = lazy_ope(lazy[k * 2 + 2], lazy[k]);
        flag[k * 2 + 2] = true;
      }

      flag[k] = false;
      lazy[k] = l_ide();
    }
  }
  
  /* for i in [a, b) effect(a[i], lx) */
  void update(i64 a, i64 b, L lx, i64 l = 0, i64 r = -1, i64 k = 0) {
    if(r < 0) r = n;
    eval(l, r, k);
    if(b <= l || r <= a) return;
    else if(a <= l && r <= b) {
      lazy[k] = lazy_ope(lazy[k], lx);
      flag[k] = true;
      eval(l, r, k);
    }
    else {
      update(a, b, lx, l, (l + r) / 2, k * 2 + 1);
      update(a, b, lx, (l + r) / 2, r, k * 2 + 2);
      node[k] =ope(node[k * 2 + 1], node[k * 2 + 2]);
    }
  }
  
  /* the sum of a[i] for i in [a, b) */
  T get(i64 a, i64 b, i64 l = 0, i64 r = -1, i64 k = 0) {
    if(r < 0) r = n;
    eval(l, r, k);
    if(b <= l || r <= a) return t_ide();
    else if(a <= l && r <= b) return node[k];
    else return ope(get(a, b, l, (l + r) / 2, k * 2 + 1), get(a, b, (l + r) / 2, r, k * 2 + 2));
  }
};


int main() {
  i64 N, Q;
  cin >> N >> Q;
  eulartour_subtree eular(N);
  rep(i,1,N) {
    i64 p;
    cin >> p;
    p--;
    eular.add_edge(p, i);
  }
  i64 len;
  vector<pair<i64, i64>> c(len = eular.start_tour(0));
  rep(i,0,N) {
    char w;
    cin >> w;
    if(w == 'G') c[eular.update_point(i)] = {1, -1};
    else c[eular.update_point(i)] = {-1, 1};
  }
  lazy_segment_tree seg(c);
  rep(i,0,Q) {
    i64 v;
    cin >> v;
    v--;
    auto p = eular.subtree_range(v);
    seg.update(p.first, p.second + 1, 1);
    i64 ans = seg.get(0, len).first;
    if(ans > 0) {
      cout << "broccoli" << endl;
    }
    else {
      cout << "cauliflower" << endl;
    }
  }
}



Measured memory_bytes: 33936