/**
 * This exercise requires finding the common elements between two lists
 * using the 'in' operator and iteration.
 */
fun findCommonElements(list1: List<Any>, list2: List<Any>): List<Any> {

    val commonElements = mutableListOf<Any>()

    // Iterate through each element in list1
    for (element in list1) {
        // Use the 'in' operator to check if the element is present in list2
        if (element in list2) {
            // Append the common element to the list
            commonElements.add(element)
        }
    }

    return commonElements
}
/**
 * This exercise requires finding the common elements between two lists
 * using the 'in' operator and iteration.
 */
fun findCommonElements(list1: List<Any>, list2: List<Any>): List<Any> {
/**
 * This exercise requires finding the common elements between two lists
 * using the 'in' operator and iteration.
 */
fun findCommonElements(list1: List<Any>, list2: List<Any>): List<Any> {

    val commonElements = mutableListOf<Any>()

    // Iterate through each element in list1
    for (element in list1) {
        // Use the 'in' operator to check if the element is present in list2
        if (element in list2) {
            // Append the common element to the list
            commonElements.add(element)
        }
    }

    return commonElements
}