<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def ensure_subclass(value, types):
 """ Ensure value is a subclass of types Traceback (most recent call last):
 TypeError: """

    ensure_class(value)
    if not issubclass(value, types):
        raise TypeError(
            "expected subclass of {}, not {}".format(
                types, value))