def reverse(text):
count=1
mylist=[]
for i in range(0,len(text)):
mylist.append(text[len(text) - count])
count=count +1
return mylist
if__name__=="__main__":
print reverse('parag')
count=1
mylist=[]
for i in range(0,len(text)):
mylist.append(text[len(text) - count])
count=count +1
return mylist
if__name__=="__main__":
print reverse('parag')
No comments:
Post a Comment