def foo(**kw):
    for k, v in list(kw.items()):
        print(k, v)
foo(a=2)
foo(a=3, b=4)
foo(nonsene=True, blather=False)
Passing keyword arguments to a function when local variable names are same as function parameter names