Go: package main

import (
	"bufio"
	"fmt"
	"os"
	"strings"
)

var scanner = bufio.NewScanner(os.Stdin)

func main() {
	var n int
	fmt.Scanf("%d", &n)

	result := make([]string, n, n)

	for i := 0; i < n; i++ {
		scanner.Scan()
		input := scanner.Text()

		result[i] = strings.Replace(input, "Hoshino", "Hoshina", -1)
	}

	for _, v := range result {
		fmt.Println(v)
	}
}

Python: for i in range(int(input())):
    print(input().replace("Hoshino","Hoshina"))

Python: if __name__ == '__main__':
    n = input()
    for line in range(int(n)):
        print(input().replace('Hoshino', 'Hoshina'))

Python: for i in range(int(input())):
    print (raw_input().replace('Hoshino', 'Hoshina'))

Python: a = input()
for i in range(int(a)):
    b = input()
    print(b.replace('Hoshino','Hoshina'))

Python: for i in range(int(input())):
    print(input().replace("Hoshino","Hoshina"))

C++: #include<stdio.h>
int main(){
	char s[1100];
	int n;
	scanf("%d",&n);
	getchar();
	for(int i=0;i<n;i++){
		fgets(s,1100,stdin);
		int j;
		for(j=0;s[j]!='\0';j++)
			if(s[j]=='H'&&s[j+1]=='o'&&s[j+2]=='s'&&s[j+3]=='h'&&s[j+4]=='i'&&s[j+5]=='n'&&s[j+6]=='o')s[j+6]='a';
		printf("%s",s);
		s[0]='\0';}
	return 0;}

C++: #include <cstdio>
#include <cstring>

int main(void)
{
	int N;
	char c;

	scanf("%d", &N);
	scanf("%c", &c);
	while(--N, N>=0){
		char instr[1001];
		char *t;

		gets(instr);
		while( (t = strstr(instr, "Hoshino")) != NULL){
			t += 6;
			*t = 'a';
		}

		printf("%s\n", instr);
	}


	return 0;
}

C++: #include<stdio.h>
#include<string.h>
int main(void)
{
	int ct;
	char* rp;
	char retu[1000];
	scanf("%d",&ct);
	//fflush(stdin);
	getchar();
	for(int f1=0;f1<ct;f1++){
		gets(retu);
		while(1){
			if(strstr(retu,"Hoshino")==NULL){
				break;
			}
			if(rp=strstr(retu,"Hoshino")){
				rp+=6;
				*rp='a';
			}
		}
		printf("%s\n",retu);
	}
	return 0;
}

C++: #include <iostream>
#include <string>

int main(){
  int n;
  int i = 0;
  std::string str;

  std::cin >> n;

  while(n > 0){
    
    //文字列の読み込み
    while(std::cin >> str){
        ++i;
    //"Hishino"を"Hoshina"に変換
        if(str.find("Hoshino") != std::string::npos)
            str = "Hoshina";
        
        std::cout << str << std::endl;
    }
        --n;
  }
}

C++: #include<iostream>
#include<string>
#include<cstdio>
#include<algorithm>
#include<stack>
#include<queue>
#include<vector>
#include<cmath>
#include<utility>
#include<set>
#include<complex>
#include<map>
#define vi vector<int>
#define vvi vector<vector<int> >
#define ll long long int
#define vl vector<ll>
#define vvl vector<vector<ll>>
#define vb vector<bool>
#define vc vector<char>
#define vs vector<string>
#define ld long double
#define INF 1e9
#define EPS 0.0000000001
#define rep(i,n) for(int i=0;i<n;i++)
#define loop(i,s,n) for(int i=s;i<n;i++)
#define CC puts("-------ok--------");
#define all(in) in.begin(), in.end()
using namespace std;
typedef pair<int, int> pii;
#define MAX 99999999
int main(){
    int n;cin>>n;
    char c; scanf("%c",&c);
    rep(p,n){
        string s;
    getline(cin,s);
            rep(i,s.length()){
        int b=(int)s.find("Hoshino",i);
        if(b!=-1)s.replace(b+i,7,"Hoshina");
    }
        cout<<s<<endl;
    }
}

C++: #include<iostream>
#include<cstring>
using namespace std;
int main(){
	int n;
	char s[1050],ha[]="Hoshina",ho[]="Hoshino";
	cin>>n;
	while(n-->0){
		fgets(s,1050,stdin);
		for(int i=0;i<strlen(s);i++){
			if(!strncmp(&s[i],ho,7)&&(s[i+7]==' '||s[i+7]=='\n'||s[i+7]=='\0')){
				strncpy(&s[i],ha,7);
			}
		}
		cout<<s;
	}
	return 0;
}

C++: #include <iostream>
#include <string>
   
int main(){
    const std::string wrong_word("Hoshino");
    const std::string right_word("Hoshina");
     
    int num;
    std::cin >> num;
    std::cin.ignore(); // ignore next newline character
       
    for(int i = 0; i < num; ++i){
        std::string str;
        std::getline(std::cin, str);
         
        std::size_t pos = str.find(wrong_word);
        while(pos != std::string::npos){
            str.replace(pos, wrong_word.length(), right_word);
            pos = str.find(wrong_word);
        }
         
        std::cout << str << std::endl;
    }
    return 0;
}

C++: #include <iostream>
#include <string>
using namespace std;

int main(void)
{
	string str;
	int n;


	cin >> n;
	while(--n,n>=0){
		getline(cin,str);

		for(int i = 0; i < str.length()-7; i++){
			if(str.substr(i,7) == "Hoshino")
				str[i+6] = 'a';
		}
		cout << str << endl;
	}
	return 0;
}

C++: #include <iostream>
#include <string>
using namespace std;

const string a = "Hoshino";
const string b = "Hoshina";
int n;
string str;

int main()
{
	cin >> n;
	cin.get();
	while (n--)
	{
		getline(cin, str);
		for (int i = 0; i <= (int)str.size() - (int)a.size(); i++)
		{
			if (str.substr(i, a.size()) == a) str.replace(i, b.size(), b);
			else if (str.substr(i, b.size()) == b) str.replace(i, a.size(), a);
		}
		cout << str << endl;
	}

	return 0;
}

C++: #include <iostream>
#include <vector>
using namespace std;

int main(){
	int n;
	cin >> n;
	string s;
	getline(cin,s);
	while(n--){
		vector<int> b;
		getline(cin,s);
		int pos = 0;
		while(~s.find("Hoshino",pos)){
			pos = s.find("Hoshino",pos)+1;
			b.push_back(pos-1);
		}
		for(int i=0;i<b.size();i++)
			s.replace(b[i],7,"Hoshina");
		cout << s << endl;
	}
}

C++: #include <iostream>
#include <cstdio>

using namespace std;

int main() {
	int n; cin >> n;

	string rect = "Hoshino";

	for (int t = 0; t < n; ++t) {
		char str[2000];
		while (scanf("%s", str) != EOF) {
			for (int i = 0; str[i]; ++i) {
				for (int j = 0; j < rect.size() && str[i+j]; ++j) {
					if (str[i+j] != rect[j]) break;
					else if (j == rect.size()-1) str[i+j] = 'a';
				}
			}

			cout << str;

			char c = getchar();
			if (c != ' ') break;

			cout << " ";
		}
		cout << endl;
	}
}

C++: #include <iostream>
#include <string>

using namespace std;

const string src = "Hoshino";
bool check(string str,int n,int m){
    if(str[n]==src[m]){
        if(m==6) return true;
        return check(str,n+1,m+1);
    }
        return false;
}
int main(){
    int n;
    scanf("%d",&n);
    string *str=new string[n];
    for(int i=0;i<n+1;i++){
        getline(cin,str[i]);
        for(int j=0;j<str[i].size();j++){
            if(check(str[i],j,0)){
                str[i][j+6]='a';
                j+=5;
            }
        }
    }
    for(int i=0;i<n+1;i++){
        cout << str[i];
        if(i) cout << endl;
    }
}

C++: #include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <iostream>
using namespace std;

int main()
{
	int i, max;
	string str[1000];
	cin >> max; getchar();
	for(i = 0; i < max; i++)
		getline(cin, str[i]);

	for(i = 0; i < max; i++)
	{
		string::size_type pos(str[i].find("Hoshino"));
		while(pos != string::npos)
		{
			str[i].replace(pos, strlen("Hoshina"), "Hoshina");
			pos = str[i].find("Hoshino", pos + strlen("Hoshina"));
		}
		cout << str[i] << endl;
	}
}

C++: #include<iostream>
#include<string>
int main(){
	int a;
	std::cin>>a;
	std::cout<<std::endl;
	for(int i=0;i<a+1;i++){
		std::string str;
		std::getline(std::cin,str);
		for(int j=0;j<str.size();j++){
			if(str[j]=='H'&&str[j+1]=='o'&&str[j+2]=='s'&&str[j+3]=='h'&&str[j+4]=='i'&&str[j+5]=='n'&&str[j+6]=='o'){
				str[j+6]='a';
			}
		}
		std::cout<<str<<std::endl;
	}

	return 0;
}

C++: #include <bits/stdc++.h>
using namespace std;

signed main() {
    int n;
    scanf("%d%*c", &n);
    for(int i=0; i<n; ++i) {
        string s;
        getline(cin, s);
        regex re("Hoshino");
        cout << regex_replace(s, re, "Hoshina") << endl;
    }
    return 0;
}

C++: #include <iostream>
#include <string>

int main(){
	int num;
	std::string english,dammy;
	std::cin >> num;
	std::getline(std::cin,dammy);
	for(int i=0;i<num;++i){
		std::getline(std::cin,english);
		while(english.find("Hoshino") != -1){
			size_t find = english.find("Hoshino");
			english.replace(find, 7, "Hoshina");
		}

		std::cout << english << std::endl;
	}
    return 0;
}