What's the recommended way of adding a docstring for a dictionary parameter? I can see multiple line docstring examples here.
I need to document the input arguments to a function in the docstring. If it's a simple variable, I can use something like:
def func2(a=x, b = y):
""" fun2 takes two integers
Keyword arguments:
a -- refers to age (default 18)
b -- refers to experience (default 0)
"""
If we have dict
passed as input argument to function:
def func3(**kwargs):
""" takes dictionary as input
<Here how to explain them - Is it like?>
kwargs['key1'] -- takes value1
<or simply>
key1 -- takes value1
"""