PygLatin

Objective – The Objective of this Lab was to utilize CodeCademy to learn how to make a Piglatin Converter using Python

Code –

pyg = ‘ay’

original = raw_input(‘Enter a word:’)
word = original.lower()
first = word[0]
new_word = word + first + pyg
new_word = new_word[1:len(new_word)]
if len(original) > 0 and original.isalpha():
print original
else:
print ’empty’

piglatin

 

Leave a Reply

Your email address will not be published. Required fields are marked *