/**
 * Create a code that takes two numbers, start and end, and returns a list containing the numbers
 * from start to end (inclusive). Then, iterate over the list using a for loop to print each number
 * multiplied by its index in the list.
 *
 * @param start The starting number
 * @param end The ending number
 */
fun createListAndIterate(start: Int, end: Int) {

    // Create a list containing the numbers from start to end
    val numbersList = (start..end).toList()

    // Iterate over the list and print each number multiplied by its index
    numbersList.forEachIndexed { index, num ->
        println(num * index)
    }
}
/**
 * Create a code that takes two numbers, start and end, and returns a list containing the numbers
 * from start to end (inclusive). Then, iterate over the list using a for loop to print each number
 * multiplied by its index in the list.
 *
 * @param start The starting number
 * @param end The ending number
 */
fun createListAndIterate(start: Int, end: Int) {
/**
 * Create a code that takes two numbers, start and end, and returns a list containing the numbers
 * from start to end (inclusive). Then, iterate over the list using a for loop to print each number
 * multiplied by its index in the list.
 *
 * @param start The starting number
 * @param end The ending number
 */
fun createListAndIterate(start: Int, end: Int) {

    // Create a list containing the numbers from start to end
    val numbersList = (start..end).toList()

    // Iterate over the list and print each number multiplied by its index
    numbersList.forEachIndexed { index, num ->
        println(num * index)
    }
}