/**
 * Create a function that takes in two lists and returns a list of elements that are common in both lists.
 */
fun commonElements(list1: List<Any>, list2: List<Any>): List<Any> {

    // Initialize an empty list to store the common elements
    val commonElementsList = mutableListOf<Any>()

    // Iterate through each element in the first list
    for (element in list1) {
        // Check if the element is also present in the second list
        if (element in list2) {
            // Add the common element to the commonElementsList
            commonElementsList.add(element)
        }
    }

    // Return the list of common elements
    return commonElementsList
}
/**
 * Create a function that takes in two lists and returns a list of elements that are common in both lists.
 */
fun commonElements(list1: List<Any>, list2: List<Any>): List<Any> {
/**
 * Create a function that takes in two lists and returns a list of elements that are common in both lists.
 */
fun commonElements(list1: List<Any>, list2: List<Any>): List<Any> {

    // Initialize an empty list to store the common elements
    val commonElementsList = mutableListOf<Any>()

    // Iterate through each element in the first list
    for (element in list1) {
        // Check if the element is also present in the second list
        if (element in list2) {
            // Add the common element to the commonElementsList
            commonElementsList.add(element)
        }
    }

    // Return the list of common elements
    return commonElementsList
}