<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_state(cls, clz):
 """ Retrieve the state of a given Class. :param clz: types.ClassType :return: Class state. :rtype: dict """

        if clz not in cls.__shared_state:
            cls.__shared_state[clz] = (
                clz.init_state() if hasattr(clz, "init_state") else {}
            )
        return cls.__shared_state[clz]