#include <bits/stdc++.h>
using namespace std;
int n, q;
class edge {
 public:
  int cnt[27], s, e, nxt, len;
  edge() {}
  edge(int e1) {
    memset(cnt, 0, sizeof(cnt));
    e = e1;
    len = 0;
    nxt = -1;
  }
} g[150010];
int head[150010], ecnt = 0, fa[150010], id[150010], len[150010], f[150010][27],
                  lft[150010], cntil, stdep, vl[150010];
vector<pair<int, int> > v[150010];
char s[5];
bool hasans = 1;
void update(int pos) {
  if (lft[pos] < 0) cntil--;
  memset(f[pos], 0, sizeof(f[pos]));
  for (int p = head[pos]; p != -1; p = g[p].nxt) {
    edge &x = g[p];
    for (int i = 0; i <= 26; i++)
      f[pos][i] = max(f[pos][i], f[x.e][i] + x.cnt[i]);
  }
  lft[pos] = len[pos];
  for (int i = 1; i <= 26; i++) lft[pos] -= f[pos][i];
  if (lft[pos] < 0) cntil++;
}
edge compress(int pos, int top, int dep) {
  if (v[pos].size() == 0) {
    if (!stdep)
      stdep = dep;
    else
      hasans &= (stdep == dep);
    len[pos] = 0;
    return edge(pos);
  } else if (v[pos].size() == 1 && pos != top) {
    edge tmp = compress(v[pos][0].first, top, dep + 1);
    tmp.cnt[v[pos][0].second]++;
    tmp.len++;
    return tmp;
  } else {
    for (auto &x : v[pos]) {
      edge tmp = compress(x.first, pos, dep + 1);
      tmp.cnt[x.second]++;
      tmp.len++;
      len[pos] = len[tmp.e] + tmp.len;
      for (int i = 0; i < 27; i++)
        f[pos][i] = max(f[pos][i], f[tmp.e][i] + tmp.cnt[i]);
      tmp.s = pos;
      g[ecnt] = tmp;
      g[ecnt].nxt = head[pos];
      head[pos] = ecnt++;
    }
    return edge(pos);
  }
}
int main() {
  memset(head, 255, sizeof(head));
  scanf("%d%d", &n, &q);
  for (int i = 2, ti, tj; i <= n; i++) {
    scanf("%d%s", &ti, s);
    if (s[0] == '?')
      tj = 0;
    else
      tj = s[0] - 'a' + 1;
    v[ti].push_back(make_pair(i, tj));
    fa[i] = ti;
    vl[i] = tj;
  }
  compress(1, 1, 1);
  if (!hasans) {
    while (q--) puts("Fou");
    return 0;
  }
  for (int i = 1; i <= n; i++) {
    for (int j = head[i]; j != -1; j = g[j].nxt) {
      int p = g[j].e;
      for (; p != i; p = fa[p]) id[p] = j;
    }
  }
  for (int i = 1; i <= n; i++) {
    if (head[i] != -1) {
      lft[i] = len[i];
      for (int j = 1; j <= 26; j++) lft[i] -= f[i][j];
      if (lft[i] < 0) cntil++;
    }
  }
  while (q--) {
    int x, y;
    scanf("%d%s", &x, s);
    if (s[0] == '?')
      y = 0;
    else
      y = s[0] - 'a' + 1;
    g[id[x]].cnt[vl[x]]--;
    vl[x] = y;
    g[id[x]].cnt[vl[x]]++;
    int np = g[id[x]].s;
    while (1) {
      update(np);
      if (np == 1) break;
      np = g[id[np]].s;
    }
    if (cntil == 0) {
      int ret = 0;
      for (int i = 1; i <= 26; i++) ret += i * (f[1][i] + lft[1]);
      printf("Shi %d\n", ret);
    } else
      puts("Fou");
  }
  return 0;
}
