I have this list
[[\'obytay\'], [\'ikeslay\'], [\'ishay\'], [\'artway\']]
where I need it to look like
obytay ikeslay ishay ar
def pig_latin(text):
say = ""
x=[]
# Separate the text into words
words = text.split()
for word in words:
# Create the pig latin word and add it to the list
x.append(word[1:]+word[0]+'ay')
for eachword in x:
say += eachword+' '
# Turn the list back into a phrase
return say
print(pig_latin("hello how are you")) # Should be "ellohay owhay reaay ouyay"
print(pig_latin("programming in python is fun")) # Should be "rogrammingpay niay ythonpay siay unfay"