Hacker News new | ask | show | jobs
by raverbashing 3821 days ago
Nah, do it like this

def foo(i,x=[]):

    x.append(i)
    
    return x
foo(1)

foo(2)

See what happens