#include <bits/stdc++.h>
int main(void) {
  int n, l, i;
  char s[1024], *t;
  scanf("%d\n", &n);
  for (i = 0; i < n; i++) {
    memset(s, 0, sizeof(s));
    fgets(s, 1001, stdin);
    while (t = strstr(s, "Hoshino"), t != NULL) {
      t[6] = 'a';
    }
    printf("%s", s);
  }
  return 0;
}
