On Thu, 12 Apr 2001 15:45:00 +1000, zzzzz <zzizz_ at notmail.com> wrote: >a) Directly modify the parameter: >x=[1,2,3] >def add4tolist(inputlist): > inputlist.append(4) >add4tolist(x) >x >[1,2,3,4] <snip> >a) is simpler, however, it only works on immutable type oops make that mutable!!!!!!! Regards, zzzzz. ---------------------
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4