/**
 * This function takes two sets as input and returns the common elements between them.
 *
 * @param set1 The first set.
 * @param set2 The second 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>()

    for (elem in set1) {
        for (ele in set2) {
            if (elem == ele) {
                commonElements.add(elem)
                break  // Exiting the inner loop
            }
        }
    }

    return commonElements
}
/**
 * This function takes two sets as input and returns the common elements between them.
 *
 * @param set1 The first set.
 * @param set2 The second set.
 * @return A set containing the common elements between set1 and set2.
 */
fun findCommonElements(set1: Set<Any>, set2: Set<Any>): Set<Any> {
/**
 * This function takes two sets as input and returns the common elements between them.
 *
 * @param set1 The first set.
 * @param set2 The second 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>()

    for (elem in set1) {
        for (ele in set2) {
            if (elem == ele) {
                commonElements.add(elem)
                break  // Exiting the inner loop
            }
        }
    }

    return commonElements
}