Saved Bookmarks
| 1. |
Find the output of the following Python program:def makenew(mystr):newstr = " "count = 0for i in mystr:if count%2 !=0:newstr = newstr+str(count)else:if islower(i):newstr = newstr+upper(i)else:newstr = newstr+icount +=1newstr = newstr+mystr[:1]print "The new string is :",newstrmakenew(“sTUdeNT") |
|
Answer» The new string is: S1U3E5Ts |
|