N = int(input()) for _ in range(N): s = list(map(str,input().split())) val = int(s[2]) + 1 print("Hitsuji ga " + str(val) + " hiki")