/**
 * This function takes in two lists and returns a new list containing the common elements between them.
 */
fun findCommonElements(list1: List<Any>, list2: List<Any>): List<Any> {

    val commonElements = mutableListOf<Any>()

    // Iterate through each element of the first list
    for (element1 in list1) {
        // Iterate through each element of the second list
        for (element2 in list2) {
            // Check if the elements are equal
            if (element1 == element2) {
                // Check if the common element is already in the commonElements list
                if (!commonElements.contains(element1)) {
                    commonElements.add(element1)
                }
            }
        }
    }

    return commonElements
}
/**
 * This function takes in two lists and returns a new list containing the common elements between them.
 */
fun findCommonElements(list1: List<Any>, list2: List<Any>): List<Any> {
/**
 * This function takes in two lists and returns a new list containing the common elements between them.
 */
fun findCommonElements(list1: List<Any>, list2: List<Any>): List<Any> {

    val commonElements = mutableListOf<Any>()

    // Iterate through each element of the first list
    for (element1 in list1) {
        // Iterate through each element of the second list
        for (element2 in list2) {
            // Check if the elements are equal
            if (element1 == element2) {
                // Check if the common element is already in the commonElements list
                if (!commonElements.contains(element1)) {
                    commonElements.add(element1)
                }
            }
        }
    }

    return commonElements
}