#include<iostream>
#include<string>
#include<cstring>

using namespace std;

int main(void)
{
	int n;
	string a;
	string g = "Hoshino";

	cin >> n;
		cin.ignore();
		for (int i = 0; i < n; ++i){
			int x = 0;
			getline(cin, a);
			if ((x = a.find("Hoshino")) >= 0)
				a.replace(x, g.length(), "Hoshina");
			cout << a << endl;
		}
	
	return 0;
}