Answers for "pig latin translator python"

1

pig latin translator python

def pig_latin(word):
    word = word.strip().lower()
    pig_latin =''
    vowel = ['a','e','i','o','u']
    for i in range(len(word)):
        if word[i] in vowel:
            if i==0:
                word+="w"
            pig_latin+=word[i:]+word[0:i]+"ay"
            break
    return pig_latin
Posted by: Guest on October-07-2021

Python Answers by Framework

Browse Popular Code Answers by Language