How to pass function as argument without executing it? [closed]
package2.b(do_this, do_that)
is a function call (a function name followed by parenthesis). Instead you should be passing only the function name package2.b
the function a
You will also need to modify function a
such that function be is called when the condition is satisfied
# function a definition
def a(one, two, the_argument_function, argument_dict):
if one in two:
return the_argument_function(**argument_dict)
def b(do_this, do_that):
print "hi."
# function call for a
a(one, two, b, {'do_this': some_value, 'do_that': some_other_value})