/**
 * This function takes in two lists and returns a set of common elements between them using break and continue statements.
 *
 * @param list1 List containing elements
 * @param list2 List containing elements
 * @return Set of common elements between list1 and list2
 */
fun getCommonElements(list1: List<Int>, list2: List<Int>): Set<Int> {

    val commonElements = mutableSetOf<Int>()

    for (element1 in list1) {
        for (element2 in list2) {
            if (element1 == element2) {
                commonElements.add(element1)
                break
            } else if (element1 < element2) {
                continue
            } else {
                break
            }
        }
    }

    return commonElements
}
/**
 * This function takes in two lists and returns a set of common elements between them using break and continue statements.
 *
 * @param list1 List containing elements
 * @param list2 List containing elements
 * @return Set of common elements between list1 and list2
 */
fun getCommonElements(list1: List<Int>, list2: List<Int>): Set<Int> {
/**
 * This function takes in two lists and returns a set of common elements between them using break and continue statements.
 *
 * @param list1 List containing elements
 * @param list2 List containing elements
 * @return Set of common elements between list1 and list2
 */
fun getCommonElements(list1: List<Int>, list2: List<Int>): Set<Int> {

    val commonElements = mutableSetOf<Int>()

    for (element1 in list1) {
        for (element2 in list2) {
            if (element1 == element2) {
                commonElements.add(element1)
                break
            } else if (element1 < element2) {
                continue
            } else {
                break
            }
        }
    }

    return commonElements
}