/**
 * This function takes a list of numbers and an iterable of elements and finds the intersection
 * between the numbers in the list and the elements in the tuple created using the tuple() function.
 *
 * @param numbersList A list of numbers.
 * @param tupleElements An iterable of elements.
 * @return A list containing the intersection between numbersList and tupleElements.
 *
 * Example:
 * intersectionOfInStatementAndTupleCreation(listOf(1, 2, 3, 4), listOf(2, 4, 6)) // [2, 4]
 */
fun intersectionOfInStatementAndTupleCreation(numbersList: List<Int>, tupleElements: Iterable<Int>): List<Int> {

    // Convert tupleElements to a tuple using the toList() function
    val tupleElementsList = tupleElements.toList()

    // Initialize an empty list to store the intersection
    val intersectionList = mutableListOf<Int>()

    // Iterate through each number in numbersList
    for (number in numbersList) {
        // Check if the number is in tupleElementsList
        if (number in tupleElementsList) {
            // Append the number to the intersectionList
            intersectionList.add(number)
        }
    }

    // Return the intersectionList
    return intersectionList
}
/**
 * This function takes a list of numbers and an iterable of elements and finds the intersection
 * between the numbers in the list and the elements in the tuple created using the tuple() function.
 *
 * @param numbersList A list of numbers.
 * @param tupleElements An iterable of elements.
 * @return A list containing the intersection between numbersList and tupleElements.
 *
 * Example:
 * intersectionOfInStatementAndTupleCreation(listOf(1, 2, 3, 4), listOf(2, 4, 6)) // [2, 4]
 */
fun intersectionOfInStatementAndTupleCreation(numbersList: List<Int>, tupleElements: Iterable<Int>): List<Int> {
/**
 * This function takes a list of numbers and an iterable of elements and finds the intersection
 * between the numbers in the list and the elements in the tuple created using the tuple() function.
 *
 * @param numbersList A list of numbers.
 * @param tupleElements An iterable of elements.
 * @return A list containing the intersection between numbersList and tupleElements.
 *
 * Example:
 * intersectionOfInStatementAndTupleCreation(listOf(1, 2, 3, 4), listOf(2, 4, 6)) // [2, 4]
 */
fun intersectionOfInStatementAndTupleCreation(numbersList: List<Int>, tupleElements: Iterable<Int>): List<Int> {

    // Convert tupleElements to a tuple using the toList() function
    val tupleElementsList = tupleElements.toList()

    // Initialize an empty list to store the intersection
    val intersectionList = mutableListOf<Int>()

    // Iterate through each number in numbersList
    for (number in numbersList) {
        // Check if the number is in tupleElementsList
        if (number in tupleElementsList) {
            // Append the number to the intersectionList
            intersectionList.add(number)
        }
    }

    // Return the intersectionList
    return intersectionList
}