#include <iostream>
#include <vector>
#include <algorithm>
#include <string>
#include <map>
#include <cmath>
#include <queue>
#include <numeric>
#include <climits>
#include <iterator>
#include <iomanip>
#include <stack>
#include <set>
#include <cstdio>
#include <bitset>
#include <functional>
#include <tuple>
#include <list>
#include <deque>
#include <sstream>
using namespace std;
typedef pair<int, int> P;

#define FOR(i, a, n) for (ll i = (ll)a; i<(ll)n; ++i)
#define REP(i, n) FOR(i, 0, n)

typedef long long ll;
typedef vector<int> VI;
int GCD(int a, int b){
    if(b==0) return a;
    return GCD(b, a%b);
}

int main() {
    int n; cin >> n;
    cin.ignore();
        for(int i=0; i<n; ++i){
            string s; getline(cin, s);
            int m=s.size();
            for(int i=0; i<m; ++i){
                if(s[i]=='H'&&s[i+1]=='o'&&s[i+2]=='s'&&s[i+3]=='h'&&s[i+4]=='i'&&
                   s[i+5]=='n'&&s[i+6]=='o'){
                    s[i+6] ='a';
                }
            }
            cout << s <<  endl;
        }
    
    
    
	return 0;
}
