<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def getfield(f):
 """convert values from cgi.Field objects to plain values."""

    if isinstance(f, list):
        return [getfield(x) for x in f]
    else:
        return f.value