<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_field_type(f):
 """Obtain the type name of a GRPC Message field."""

    types = (t[5:] for t in dir(f) if t[:4] == 'TYPE' and
             getattr(f, t) == f.type)
    return next(types)