#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 5e4 + 5;
int n, q;
int w[N];
vector<int> g[N];
int W(char c) {
  if (c == '?') return 26;
  return c - 'a';
}
set<int> st;
int dep[N], cnt = 0, H = 0, p[N], id[N], fa[N];
vector<int> V[N];
void dfs(int u, int p) {
  fa[u] = p;
  dep[u] = dep[p] + 1;
  id[u] = u;
  H = max(H, dep[u]);
  if ((int)g[u].size() == 0) st.insert(dep[u]);
  for (auto v : g[u]) dfs(v, u);
  if ((int)g[u].size() == 1) id[u] = id[g[u][0]], fa[id[g[u][0]]] = fa[u];
}
int bad = 0;
int mx[N][28], sum[N], num[N][28];
bool b[N];
inline void upd(int u, int d, int _w) {
  num[u][_w] += d;
  for (; fa[u] != -1; u = fa[u]) {
    bad -= b[fa[u]];
    int pre = mx[fa[u]][_w];
    mx[fa[u]][_w] = 0;
    for (auto v : g[fa[u]])
      mx[fa[u]][_w] = max(mx[fa[u]][_w], mx[id[v]][_w] + num[id[v]][_w]);
    sum[fa[u]] += mx[fa[u]][_w] - pre;
    if (sum[fa[u]] <= H - dep[fa[u]])
      b[fa[u]] = 0;
    else
      b[fa[u]] = 1;
    bad += b[fa[u]];
  }
}
int main() {
  scanf("%d%d", &n, &q);
  char op[2];
  for (int i = (2); i < (n + 1); i++) {
    scanf("%d%s", &p[i], op);
    g[p[i]].push_back(i);
    w[i] = W(op[0]);
  }
  dep[0] = -1;
  fa[0] = -1;
  g[0].push_back(1);
  dfs(1, 0);
  w[1] = 0;
  for (int i = (1); i < (n + 1); i++)
    if (w[i] <= 25) upd(id[i], 1, w[i]);
  if ((int)st.size() != 1) {
    for (int i = (1); i < (q + 1); i++) printf("Fou\n");
    return 0;
  }
  int v, ct;
  for (int i = (1); i < (q + 1); i++) {
    scanf("%d%s", &v, op);
    if (w[v] <= 25) upd(id[v], -1, w[v]);
    w[v] = W(op[0]);
    if (w[v] <= 25) upd(id[v], 1, w[v]);
    if (bad == 0) {
      printf("Shi ");
      int ss = 0;
      mx[0][0]--;
      ss = sum[0] - 1;
      int mark = H - ss;
      long long ans = 0;
      for (int i = (0); i < (26); i++)
        ans += (long long)(mx[id[0]][i] + mark) * (i + 1);
      printf("%lld\n", ans);
      mx[0][0]++;
    } else
      printf("Fou\n");
  }
  return 0;
}
