from typing import Counter


def mode(elements):
    """
    mode(elements)

    Returns the elements with highest number of occurrence.


    Parameters
    ----------
    elements: list
        a list of elements to be counted

    Returns
    -------
    list

    Example
    -------
    a = [1,1,2,3,3]
    mode(a) # returns [1,3]
    """
    if not isinstance(elements, list):
        raise TypeError("Not a list")

    if not elements:
        raise ValueError("Empty list provided")

    counts = Counter(elements)
    max_value = max(counts.values())
    return sorted(key for key, value in counts.items() if value == max_value)