/**
 * This function takes in two lists of numbers and returns the intersection of the two lists.
 * The intersection of two lists is the set of values that are common to both lists.
 */
fun intersection(numList1: List<Int>, numList2: List<Int>): List<Int> {

    val intersectionList = mutableListOf<Int>()  // list to store the common values between the two lists

    for (num in numList1) {
        // Using short-circuiting with if-else, complete the condition to check if the number is present in numList2
        // If the number is present in numList2, add it to the intersectionList
        if (numList2.contains(num)) {
            intersectionList.add(num)
        }
    }

    return intersectionList
}
/**
 * This function takes in two lists of numbers and returns the intersection of the two lists.
 * The intersection of two lists is the set of values that are common to both lists.
 */
fun intersection(numList1: List<Int>, numList2: List<Int>): List<Int> {
/**
 * This function takes in two lists of numbers and returns the intersection of the two lists.
 * The intersection of two lists is the set of values that are common to both lists.
 */
fun intersection(numList1: List<Int>, numList2: List<Int>): List<Int> {

    val intersectionList = mutableListOf<Int>()  // list to store the common values between the two lists

    for (num in numList1) {
        // Using short-circuiting with if-else, complete the condition to check if the number is present in numList2
        // If the number is present in numList2, add it to the intersectionList
        if (numList2.contains(num)) {
            intersectionList.add(num)
        }
    }

    return intersectionList
}