using System;

namespace TestProject
{
	class MainClass
	{
		public static void Main(string[] args)
		{
			int n = int.Parse(Console.ReadLine());
			string s0 = "Hoshino";
			string s1 = "Hoshina";
			string[] s = new string[n];
			for (int i = 0; i < n; i++)
			{
				s[n] = Console.ReadLine();
				s[n].Replace(s0, s1);
			}
			foreach (var x in s)
			{
				Console.WriteLine(x);
			}
		}
	}
}