Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

how to pass on all the arguments to internal function in python

def func1(*args, **kwargs):
    func2(*args, **kwargs)

def func1(a=1, b=2, c=3):
    func2(**locals())
# locals() are all local variables, so you can't set any extra vars before calling func2 or they will get passed too.
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #pass #arguments #internal #function #python
ADD COMMENT
Topic
Name
3+4 =