def fullname(clazz):
    """
    Return fully qualified name of the given class.

    >>> from collections import Counter
    >>> fullname(Counter)
    'collections.Counter'
    """
    clazz_name = clazz.__name__ if hasattr(clazz, '__name__') else clazz._name
    return f'{clazz.__module__}.{clazz_name}'