First page Back Continue Last page Overview Graphics

Arbitrary Keyword Parameters

There is also a mechanism for an arbitrary number of keyword parameters.

To do this, we use the ** notation:

>>> def f(**kwargs):

... print(kwargs)

...

>>> f()

{}

>>> f(de="German",en="English",fr="French")

{'fr': 'French', 'de': 'German', 'en': 'English'}

>>>