V
vegetax
if i have a dictionary:
d = {'a':2,'b':3 }
l = (1,2)
how can i pass it to a generic function that takes variable keywords as
arguments? same thing with variable arguments, i need to pass a list of
arguments to the function
def asd(**kw): print kw
def efg(*arg): print arg
asd(d)
doesnt work
asd(kw = d)
doesnt work
efg(l)
doesnt work
i need to pass those as a dictionary and a list,since i dont know ahead of
time if which items would have d and l
d = {'a':2,'b':3 }
l = (1,2)
how can i pass it to a generic function that takes variable keywords as
arguments? same thing with variable arguments, i need to pass a list of
arguments to the function
def asd(**kw): print kw
def efg(*arg): print arg
asd(d)
doesnt work
asd(kw = d)
doesnt work
efg(l)
doesnt work
i need to pass those as a dictionary and a list,since i dont know ahead of
time if which items would have d and l