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