def has_two_adjacent(password):
    """Check if the password contains a pair of adjacent digits"""
    last_char = None
    num_adjacent = 0

    for char in password:
        if char == last_char:
            num_adjacent += 1
        else:
            if num_adjacent == 1:
                return True

            last_char = char
            num_adjacent = 0

    if num_adjacent == 1:
        return True
    else:
        return False