#include <iostream>
#include <string>
using namespace std;

int main() {
	int n;
	string s;

	cin >> n;
	cin.ignore();
	for(int i = 0; i < n; i++) {
		getline(cin, s);
		for(int j = s.find("Hoshino", 0); j != string::npos; j = s.find("Hoshino", j + 1)) {
			s[j + 6] = 'a';
		}
		cout << s << endl;
	}

}