#!/usr/bin/env python
import re
# tokenizes based on spaces

myline = input ("Please type expression  ")
myresult = myline.split(" ")
mystr = ""
for token in myresult:
  if token[0] == 'a':
  	mystr = mystr +  token[1:] + "ay "
  else:
  	mystr = mystr + token[1:] + token[0] + "ay "
print(mystr)
