#include<iostream>
#include<sstream>

using namespace std;
int main(){
	int n,i,j,h;
	char *p;
	char buf[1100];
	string str;
	string hit="Hoshino";
	string word="Hoshina";
	cin>>n;
	string tmp;
	getline(cin,tmp);
	for(;true;){
		string buf;
		getline(cin,buf);
		if(buf.size()==0)break;

		stringstream ss(buf);
//		cout<<"word :"<<buf<<endl;
		for(int i=0;ss >> str;i++){
			if(i)cout<<" ";
			h=str.size();
			int st=str.find(hit);
			if(st>=0)str.replace(st,word.size(),word);
			cout<<str;
		}
		cout<<endl;
	}
	return 0;
}