PygLatin2


#1

Please my new_word is not showing the PygLatin of the word entered.Here is my code:
pyg = 'ay'

original = raw_input('Enter a word:')

if len(original) > 0 and original.isalpha():
word = original.lower()
first = word[0]
new_word = word + first + pyg
new_word = new_word[1:] #slicing from the 1st index to the end
print original
else:
print 'empty'


#2

You didn't print new_word.


#3

i realised that after a code break.Problem solved.


#4

Always a great idea to take breaks!


#5

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.