def validate_password_positions(policy, password):
    """Validate password based on positions in policy."""
    positions, char = policy
    password_chars = set(password[position] for position in positions)
    return len(password_chars) == 2 and char in password_chars