#include <bits/stdc++.h>
int main(void) {
  int n, i;
  char str[1000];
  char *p, *pp;
  scanf("%d%*c", &n);
  for (i = 0; i < n; i++) {
    fgets(str, 1000, stdin);
    pp = str;
    while ((p = strstr(pp, "Hoshino")) != NULL) {
      *(p + 6) = 'a';
      pp = p + 6;
    }
    printf("%s", str);
  }
  return 0;
}
