from typing import Iterable
from typing import Any


def allunique(iterable: Iterable[Any]) -> bool:
    """Check whether all items of an iterable are distinct.

    Works for either hashable or unhashable items. If all items are
    hashable, allunique_hashable() will be much faster.

    Returns True for an empty iterable. Will not return if passed an
    infinite iterator.

    Arguments:
        iterable: object to be checked

    Returns:
        True if all items of iterable are different, otherwise False

    Examples:

    >>> allunique(range(100))
    True
    >>> allunique(iter(range(100)))
    True
    >>> allunique(list(range(100)) + [9])
    False
    >>> allunique(['alice', 'bob', 'charlie'])
    True
    >>> allunique('hi ho')
    False
    >>> allunique([['this', 'object'], ['is'], ['not', 'hashable']])
    True
    >>> allunique([])
    True

    """
    seen = []
    saw = seen.append
    return not any(item in seen or saw(item) for item in iterable)