#include <bits/stdc++.h>
using namespace std;
template <class T>
void read(T &x) {
  x = 0;
  char c = getchar();
  int flag = 0;
  while (c < '0' || c > '9') flag |= (c == '-'), c = getchar();
  while (c >= '0' && c <= '9')
    x = (x << 3) + (x << 1) + (c ^ 48), c = getchar();
  if (flag) x = -x;
}
template <class T>
T _max(T a, T b) {
  return a > b ? a : b;
}
template <class T>
T _min(T a, T b) {
  return a < b ? a : b;
}
template <class T>
bool checkmax(T &a, T b) {
  return b > a ? a = b, 1 : 0;
}
template <class T>
bool checkmin(T &a, T b) {
  return b < a ? a = b, 1 : 0;
}
const int N = 150005, SIGMA = 26;
char opt[2], str[N];
int n, q, deep = 0, flag = 0;
int fa[N], dep[N], deg[N], reality[N];
int dp[N][SIGMA], cnt[N][SIGMA], sum[N];
vector<int> G[N], newG[N];
void add_edge(int x, int y) { G[x].push_back(y); }
int dfs(int x) {
  if (!(int)G[x].size()) {
    if (!deep)
      deep = dep[x];
    else if (deep != dep[x]) {
      for (int i = 1; i <= q; ++i) printf("Fou\n");
      exit(0);
    }
    reality[x] = x;
    return x;
  }
  int tmp;
  for (int i = 0; i < (int)G[x].size(); ++i) {
    int to = G[x][i];
    dep[to] = dep[x] + 1;
    tmp = dfs(to);
    if (to != tmp) {
      for (int q = 0; q < SIGMA; ++q) {
        cnt[tmp][q] += cnt[to][q];
      }
    }
    for (int q = 0; q < SIGMA; ++q) {
      checkmax(dp[x][q], dp[tmp][q] + cnt[tmp][q]);
    }
    if (x == 1 || deg[x] == 2) {
      fa[tmp] = x;
      newG[x].push_back(tmp);
    }
    if (x != 1 && deg[x] == 1) reality[x] = tmp;
  }
  for (int q = 0; q < SIGMA; ++q) {
    sum[x] += dp[x][q];
  }
  if (x == 1 || deg[x] == 2) reality[x] = x;
  if (deg[x] == 1)
    return tmp;
  else
    return x;
}
void init() {
  read(n);
  read(q);
  for (int i = 2, x; i <= n; ++i) {
    read(x);
    scanf("%s", opt);
    add_edge(x, i);
    ++deg[x];
    if (opt[0] != '?') ++cnt[i][opt[0] - 'a'];
    str[i] = opt[0];
  }
  dfs(1);
  for (int i = 1; i <= n; ++i) {
    dep[i] = deep - dep[i];
  }
  for (int i = 1; i <= n; ++i) {
    if (reality[i] == i) {
      if (sum[i] > dep[i]) ++flag;
    }
  }
}
void update(int x, int typ) {
  while (x) {
    if (sum[x] > dep[x]) --flag;
    sum[x] -= dp[x][typ];
    dp[x][typ] = 0;
    for (int i = 0; i < (int)newG[x].size(); ++i) {
      int to = newG[x][i];
      checkmax(dp[x][typ], dp[to][typ] + cnt[to][typ]);
    }
    sum[x] += dp[x][typ];
    if (sum[x] > dep[x]) ++flag;
    x = fa[x];
  }
}
void get_ans() {
  if (flag) {
    printf("Fou\n");
    return;
  }
  int tmp = 0;
  for (int i = 0; i < SIGMA; ++i) {
    tmp += dp[1][i];
  }
  int ans = 0;
  for (int i = 0; i < SIGMA; ++i) {
    ans += (i + 1) * (deep - tmp + dp[1][i]);
  }
  printf("Shi %d\n", ans);
}
void solve() {
  int x;
  while (q--) {
    read(x);
    scanf("%s", opt);
    if (str[x] != '?') {
      --cnt[reality[x]][str[x] - 'a'];
      update(fa[reality[x]], str[x] - 'a');
    }
    if (opt[0] != '?') {
      ++cnt[reality[x]][opt[0] - 'a'];
      update(fa[reality[x]], opt[0] - 'a');
    }
    str[x] = opt[0];
    get_ans();
  }
}
int main() {
  init();
  solve();
  return 0;
}
