<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def bitdepthof(pixel):
 """Return the bitdepth for a Plan9 pixel format string."""


    maxd = 0
    for c in re.findall(r'[a-z]\d*', pixel):
        if c[0] != 'x':
            maxd = max(maxd, int(c[1:]))
    return maxd