Source Code:
(back to article)
def print_kwargs(**kwargs): for key, value in kwargs.items(): print(f"{key} = {value}") print_kwargs(name="Alice", age=20) # prints name = Alice, age = 20 print_kwargs(a=1, b=2, c=3) # prints a = 1, b = 2, c = 3
Result:
Report an issue