def is_in(sequence, part):
    """ returns true if 2-item list 'part' is in list 'sequence'
    """
    assert len(part) == 2
    for i in range(0, len(sequence) - 1):
        if sequence[i: i + 2] == part:
            return True
    return False