/**
 * This exercise requires you to write a nested while loop that performs a specific task.
 */
fun nestedWhileLoop(range1: Int, range2: Int) {

    // Initialize the first variable
    var var1 = 0

    // Start the outer loop
    while (var1 < range1) {
        // Initialize the second variable
        var var2 = 0

        // Start the inner loop
        while (var2 < range2) {
            // Your task is to complete the following code block so that it prints the product of var1 and var2
            // and increments var2 by 1.
            // Your code should fit inside this block and maintain the nested structure of the loops.

            // Your code here
            println(var1 * var2)

            // Increment var2
            var2++
        }

        // Increment var1
        var1++
    }
}

// Uncomment the code below and run it to test your implementation

// nestedWhileLoop(3, 4)

// The expected output is:
// 0
// 0
// 0
// 0
// 0
// 0
// 0
// 0
// 0
/**
 * This exercise requires you to write a nested while loop that performs a specific task.
 */
fun nestedWhileLoop(range1: Int, range2: Int) {
/**
 * This exercise requires you to write a nested while loop that performs a specific task.
 */
fun nestedWhileLoop(range1: Int, range2: Int) {

    // Initialize the first variable
    var var1 = 0

    // Start the outer loop
    while (var1 < range1) {
        // Initialize the second variable
        var var2 = 0

        // Start the inner loop
        while (var2 < range2) {
            // Your task is to complete the following code block so that it prints the product of var1 and var2
            // and increments var2 by 1.
            // Your code should fit inside this block and maintain the nested structure of the loops.

            // Your code here
            println(var1 * var2)

            // Increment var2
            var2++
        }

        // Increment var1
        var1++
    }
}

// Uncomment the code below and run it to test your implementation

// nestedWhileLoop(3, 4)

// The expected output is:
// 0
// 0
// 0
// 0
// 0
// 0
// 0
// 0
// 0