s = input() if s[-1] == "i" and s[-2] == "a": s = s[:-1] + s[-1].capitalize() s = s[:-2] + s[-2].capitalize() + s[-1] print(s) else: s += "-AI" print(s)