I have one defined function and I would like to define another one which is exactly the same as the first, but specifying one parameter.
One possible way of doing that is
def my_function(arg1, arg2):
print(arg1, arg2)
def my_function_foo(arg1):
return(my_function(arg1, 'bar'))
>>> my_function_foo('foo')
foo bar
But I suppose there is a cleaner way, closer to:
my_function_foo = my_function(arg2 = 'foo')
barforarg2, one that assumes a value of3, etc.