/**
 * Given two ranges with negative values, find the intersection of the two ranges.
 *
 * @param range1 A list representing the first range.
 * @param range2 A list representing the second range.
 * @return A list of common elements between range1 and range2.
 */
fun findIntersection(range1: List<Int>, range2: List<Int>): List<Int> {

    val intersection = mutableListOf<Int>()

    for (num1 in range1) {
        for (num2 in range2) {
            if (num1 == num2) {
                intersection.add(num1)
            }
        }
    }

    return intersection
}
/**
 * Given two ranges with negative values, find the intersection of the two ranges.
 *
 * @param range1 A list representing the first range.
 * @param range2 A list representing the second range.
 * @return A list of common elements between range1 and range2.
 */
fun findIntersection(range1: List<Int>, range2: List<Int>): List<Int> {
/**
 * Given two ranges with negative values, find the intersection of the two ranges.
 *
 * @param range1 A list representing the first range.
 * @param range2 A list representing the second range.
 * @return A list of common elements between range1 and range2.
 */
fun findIntersection(range1: List<Int>, range2: List<Int>): List<Int> {

    val intersection = mutableListOf<Int>()

    for (num1 in range1) {
        for (num2 in range2) {
            if (num1 == num2) {
                intersection.add(num1)
            }
        }
    }

    return intersection
}