<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def addParameter( self, k, r ):
 """Add a parameter to the experiment's parameter space. k is the parameter name, and r is its range. :param k: parameter name :param r: parameter range"""


        if isinstance(r, six.string_types) or not isinstance(r, collections.Iterable):
            # range is a single value (where a string constitutes a single value), make it a list
            r = [ r ]
        else:
            if isinstance(r, collections.Iterable):
                # range is an iterable, make into a list
                r = list(r)

        self._parameters[k] = r