import operator


def sequence_eq(sequence1, sequence2):
    """
    Compares two sequences.

    Parameters
    ----------
    sequence1 : sequence
        The first sequence.
    sequence2 : sequence
        The second sequence.

    Returns
    -------
    bool
        `True` iff `sequence1` equals `sequence2`, otherwise `False`.
    """
    return len(sequence1) == len(sequence2) and all(map(operator.eq, sequence1, sequence2))