/**
 * Given two lists, find and return the common elements between them.
 *
 * @param list1 The first list containing elements.
 * @param list2 The second list containing elements.
 * @return A new list containing the common elements between list1 and list2.
 */
fun findCommonElements(list1: List<Any>, list2: List<Any>): List<Any> {

    val commonElements = mutableListOf<Any>()
    for (element in list1) {
        if (element in list2) {
            commonElements.add(element)
        }
    }
    return commonElements
}
/**
 * Given two lists, find and return the common elements between them.
 *
 * @param list1 The first list containing elements.
 * @param list2 The second list containing elements.
 * @return A new list containing the common elements between list1 and list2.
 */
fun findCommonElements(list1: List<Any>, list2: List<Any>): List<Any> {
/**
 * Given two lists, find and return the common elements between them.
 *
 * @param list1 The first list containing elements.
 * @param list2 The second list containing elements.
 * @return A new list containing the common elements between list1 and list2.
 */
fun findCommonElements(list1: List<Any>, list2: List<Any>): List<Any> {

    val commonElements = mutableListOf<Any>()
    for (element in list1) {
        if (element in list2) {
            commonElements.add(element)
        }
    }
    return commonElements
}