/**
 * This function calculates the product of all the numbers between start and end (inclusive).
 *
 * @param start The starting number.
 * @param end The ending number.
 * @return The product of all the numbers between start and end.
 */
fun calculateProduct(start: Int, end: Int): Int {

    if (start > end) {
        throw IllegalArgumentException("Start must be smaller than or equal to end.")
    }

    var product = 1
    for (num in start..end) {
        product *= num
    }

    return product
}
/**
 * This function calculates the product of all the numbers between start and end (inclusive).
 *
 * @param start The starting number.
 * @param end The ending number.
 * @return The product of all the numbers between start and end.
 */
fun calculateProduct(start: Int, end: Int): Int {
/**
 * This function calculates the product of all the numbers between start and end (inclusive).
 *
 * @param start The starting number.
 * @param end The ending number.
 * @return The product of all the numbers between start and end.
 */
fun calculateProduct(start: Int, end: Int): Int {

    if (start > end) {
        throw IllegalArgumentException("Start must be smaller than or equal to end.")
    }

    var product = 1
    for (num in start..end) {
        product *= num
    }

    return product
}