/**
 * Given two arrays (arr1 and arr2) of integers, find the common multiples between the two arrays.
 *
 * @param arr1 list of integers
 * @param arr2 list of integers
 * @return list of common multiples between arr1 and arr2
 */
fun findCommonMultiples(arr1: List<Int>, arr2: List<Int>): List<Int> {

    val commonMultiples = mutableListOf<Int>()

    for (num1 in arr1) {
        for (num2 in arr2) {
            val result = num1 * num2
            if (result !in commonMultiples) {
                commonMultiples.add(result)
            }
        }
    }

    return commonMultiples
}
/**
 * Given two arrays (arr1 and arr2) of integers, find the common multiples between the two arrays.
 *
 * @param arr1 list of integers
 * @param arr2 list of integers
 * @return list of common multiples between arr1 and arr2
 */
fun findCommonMultiples(arr1: List<Int>, arr2: List<Int>): List<Int> {
/**
 * Given two arrays (arr1 and arr2) of integers, find the common multiples between the two arrays.
 *
 * @param arr1 list of integers
 * @param arr2 list of integers
 * @return list of common multiples between arr1 and arr2
 */
fun findCommonMultiples(arr1: List<Int>, arr2: List<Int>): List<Int> {

    val commonMultiples = mutableListOf<Int>()

    for (num1 in arr1) {
        for (num2 in arr2) {
            val result = num1 * num2
            if (result !in commonMultiples) {
                commonMultiples.add(result)
            }
        }
    }

    return commonMultiples
}