HomeList Manipulation What will be the output of following code? 2 Comments Facebook Twitter Q. What will be the output of following code?x = ['3', '2', '5']y = " "while x : y = y + x [-1] x = x [: len(x) -1]print (y)print (x)print (type(x), type(y))Answer =Output:-523[]<class 'list'> <class 'str'>>>>
how the output of x comes an empty list
ReplyDeletei my view the answer will 3
please explian it how ???
It takes a year for me to understand of it
DeletePost a Comment
You can help us by Clicking on ads. ^_^
Please do not send spam comment : )