def seq_is_equal(a, b):
    """
    Helper function that checks if two sequences are equal (assuming they have
    the same length).
    """
    for i in range(len(a)):
        if a[i] != b[i]:
            return False
    return True