/**
 * This exercise aims to test your understanding of unconditioned ternary operator and operations on integers.
 *
 * Given three integers, x, y, and z, your task is to return the intersection of the three numbers, i.e., the number which is present in all three.
 * You need to use the unconditioned ternary operator to solve the exercise.
 *
 * @param x The first integer.
 * @param y The second integer.
 * @param z The third integer.
 * @return The intersection of the three integers.
 *
 * Example:
 * intersectionOperator(3, 9, 12) -> 3
 * intersectionOperator(11, 96, 11) -> 11
 */
fun intersectionOperator(x: Int, y: Int, z: Int): Int {

    // Use the unconditioned ternary operator to check whether x, y, and z are equal
    return if (x == y && y == z) x else if (x == y) x else if (x == z) x else y
}
/**
 * This exercise aims to test your understanding of unconditioned ternary operator and operations on integers.
 *
 * Given three integers, x, y, and z, your task is to return the intersection of the three numbers, i.e., the number which is present in all three.
 * You need to use the unconditioned ternary operator to solve the exercise.
 *
 * @param x The first integer.
 * @param y The second integer.
 * @param z The third integer.
 * @return The intersection of the three integers.
 *
 * Example:
 * intersectionOperator(3, 9, 12) -> 3
 * intersectionOperator(11, 96, 11) -> 11
 */
fun intersectionOperator(x: Int, y: Int, z: Int): Int {
/**
 * This exercise aims to test your understanding of unconditioned ternary operator and operations on integers.
 *
 * Given three integers, x, y, and z, your task is to return the intersection of the three numbers, i.e., the number which is present in all three.
 * You need to use the unconditioned ternary operator to solve the exercise.
 *
 * @param x The first integer.
 * @param y The second integer.
 * @param z The third integer.
 * @return The intersection of the three integers.
 *
 * Example:
 * intersectionOperator(3, 9, 12) -> 3
 * intersectionOperator(11, 96, 11) -> 11
 */
fun intersectionOperator(x: Int, y: Int, z: Int): Int {

    // Use the unconditioned ternary operator to check whether x, y, and z are equal
    return if (x == y && y == z) x else if (x == y) x else if (x == z) x else y
}