I am trying to make one program using python where User has to put value which is equal to any name or any word and what it does is that it cut first letter of the word and paste it at the end of the word and adds 2 more alphabet equal to 'py'.
Ex- Enter the value: Shashank 'Output which i am getting is shashankspy' but the value which I want is 'hashankspy'
The code which i made is this:
pyg = 'ay'
original = raw_input('Enter a word:')
if len(original) > 0 and original.isalpha():
print original
word = original.lower()
first = word[0]
new_word = word + first + pyg
new_word[1:]
else:
print 'empty'
I am not able to get the real value. Please help!