/**
 * Given two sets, find and return the common elements between them.
 *
 * @param set1 First set (as a Kotlin Set)
 * @param set2 Second set (as a Kotlin Set)
 * @return A set containing the common elements between set1 and set2
 */
fun findCommonElements(set1: Set<Any>, set2: Set<Any>): Set<Any> {

    val commonElements = mutableSetOf<Any>()

    // Iterate over the elements in set1
    for (element in set1) {
        // Check if the element exists in set2
        if (element in set2) {
            // Add the element to commonElements set
            commonElements.add(element)
        }
    }

    return commonElements
}
/**
 * Given two sets, find and return the common elements between them.
 *
 * @param set1 First set (as a Kotlin Set)
 * @param set2 Second set (as a Kotlin Set)
 * @return A set containing the common elements between set1 and set2
 */
fun findCommonElements(set1: Set<Any>, set2: Set<Any>): Set<Any> {
/**
 * Given two sets, find and return the common elements between them.
 *
 * @param set1 First set (as a Kotlin Set)
 * @param set2 Second set (as a Kotlin Set)
 * @return A set containing the common elements between set1 and set2
 */
fun findCommonElements(set1: Set<Any>, set2: Set<Any>): Set<Any> {

    val commonElements = mutableSetOf<Any>()

    // Iterate over the elements in set1
    for (element in set1) {
        // Check if the element exists in set2
        if (element in set2) {
            // Add the element to commonElements set
            commonElements.add(element)
        }
    }

    return commonElements
}