/**
 * This function takes two lists as input and returns a list of common elements found in both lists.
 *
 * @param list1 the first list
 * @param list2 the second list
 * @return a list of common elements between list1 and list2
 */
fun findIntersection(list1: List<Any>, list2: List<Any>): List<Any> {

    // Initialize an empty list to store common elements between list1 and list2
    val commonElements = mutableListOf<Any>()

    // Iterate over each element in list1
    for (elem1 in list1) {
        // Check if element is present in list2
        if (elem1 in list2) {
            // Append the common element to the commonElements list
            commonElements.add(elem1)
        }
    }

    // Return the list of common elements
    return commonElements
}
/**
 * This function takes two lists as input and returns a list of common elements found in both lists.
 *
 * @param list1 the first list
 * @param list2 the second list
 * @return a list of common elements between list1 and list2
 */
fun findIntersection(list1: List<Any>, list2: List<Any>): List<Any> {
/**
 * This function takes two lists as input and returns a list of common elements found in both lists.
 *
 * @param list1 the first list
 * @param list2 the second list
 * @return a list of common elements between list1 and list2
 */
fun findIntersection(list1: List<Any>, list2: List<Any>): List<Any> {

    // Initialize an empty list to store common elements between list1 and list2
    val commonElements = mutableListOf<Any>()

    // Iterate over each element in list1
    for (elem1 in list1) {
        // Check if element is present in list2
        if (elem1 in list2) {
            // Append the common element to the commonElements list
            commonElements.add(elem1)
        }
    }

    // Return the list of common elements
    return commonElements
}