S = input().strip() if S[-2:] == 'ai': S = S[:-2]+ 'AI' else: S += '-AI' print(S)