About python while statement and pop()

hito koto hitokoto2014 at gmail.com
Wed Jun 11 23:12:23 EDT 2014


Hello,all
I'm first time,

I want to make a while statement which can function the same x.pop () and without the use of pop、how can i to do?

i want to change this is code:

def foo(x):
    y = []
    while x !=[]:
        y.append(x.pop())
    return y



More information about the Python-list mailing list