s = list(input()) n = len(s) if s[n-2] == 'a' and s[n-1] == 'i': del s[n-2:n] print(''.join(s) + 'AI') else: print(''.join(s) + '-AI')