#include <bits/stdc++.h>
using namespace std;
const int inf = 1.01e9;
const double eps = 1e-9;
const int N = 2e5 + 10;
const int L = 27;
int p[N][L];
int par[N];
int what[N];
int back[N][L];
int PAR[N];
vector<int> sons[N];
int FAIL = 0;
int t[L];
int t1[L];
int t2[L];
int bad[N];
void push(int x) {
  if (FAIL) return;
  if (((int)(sons[x]).size()) == 0) return;
  if (((int)(sons[x]).size()) == 1) {
    int y = sons[x][0];
    for (int i = 0; (i) < (L); ++i) p[x][i] = p[y][i] + back[y][i];
    bad[x] = bad[y];
    return;
  }
  int y1 = sons[x][0];
  int y2 = sons[x][1];
  for (int i = 0; (i) < (L); ++i) t1[i] = p[y1][i] + back[y1][i];
  for (int i = 0; (i) < (L); ++i) t2[i] = p[y2][i] + back[y2][i];
  int cnt1 = 0;
  int cnt2 = 0;
  for (int i = 0; (i) < (L); ++i) cnt1 += t1[i];
  for (int i = 0; (i) < (L); ++i) cnt2 += t2[i];
  if (cnt1 != cnt2) {
    FAIL = 1;
    return;
  }
  for (int i = 1; i < L; ++i) p[x][i] = max(t1[i], t2[i]);
  int cnt = 0;
  for (int i = 1; i < L; ++i) cnt += p[x][i];
  int ok = cnt1 - cnt;
  p[x][0] = ok;
  bad[x] = ok;
  bad[x] = min(bad[x], bad[y1]);
  bad[x] = min(bad[x], bad[y2]);
}
int calc() {
  if (FAIL) return -1;
  if (bad[0] < 0) return -1;
  int res = 0;
  for (int i = 1; i < L; ++i) res += i * (p[0][i] + p[0][0]);
  return res;
}
int main() {
  int n, q;
  scanf("%d%d", &n, &q);
  for (int i = 0; (i) < (n - 1); ++i) {
    int x;
    char s[3];
    scanf("%d%s", &x, s);
    --x;
    par[i + 1] = x;
    int z;
    if (s[0] == '?')
      z = 0;
    else
      z = s[0] - 'a' + 1;
    what[i + 1] = z;
    sons[x].push_back(i + 1);
  }
  for (int i = n - 1; i >= 0; --i) {
    PAR[i] = i;
    if (i > 0 && ((int)(sons[i]).size()) == 1) PAR[i] = PAR[sons[i][0]];
    back[PAR[i]][what[i]]++;
  }
  for (int x = 0; (x) < (n); ++x)
    if (x == 0 || ((int)(sons[x]).size()) >= 2)
      for (int j = 0; (j) < (((int)(sons[x]).size())); ++j) {
        sons[x][j] = PAR[sons[x][j]];
        par[sons[x][j]] = x;
      }
  for (int i = n - 1; i >= 0; --i) {
    push(i);
  }
  for (int _ = 0; (_) < (q); ++_) {
    int x;
    char s[3];
    scanf("%d%s", &x, s);
    int z = 0;
    if (s[0] != '?') z = s[0] - 'a' + 1;
    x--;
    back[PAR[x]][what[x]]--;
    what[x] = z;
    back[PAR[x]][what[x]]++;
    while (x) {
      x = par[PAR[x]];
      push(x);
    }
    int val = calc();
    if (val < 0)
      printf("Fou\n");
    else
      printf("Shi %d\n", val);
  }
  return 0;
}
