/**
 * This exercise is designed to test your knowledge of basic while loop syntax and the AND operator.
 * Your task is to write a while loop that iterates as long as both x and y are positive numbers.
 * Inside the loop, you should print the value of x, subtract 1 from x, and divide y by 2.
 * The loop should terminate when either x or y becomes negative.
 * Your task is to complete the code by filling in the missing parts.
 */
fun whileLoopAndOperator(x: Int, y: Int) {

    var xValue = x
    var yValue = y

    // Start the loop
    while (xValue > 0 && yValue > 0) {
        // Print the value of x
        println(xValue)
        // Subtract 1 from x
        xValue--
        // Divide y by 2
        yValue /= 2

        // Add your code here

    }
    // End of loop
}
/**
 * This exercise is designed to test your knowledge of basic while loop syntax and the AND operator.
 * Your task is to write a while loop that iterates as long as both x and y are positive numbers.
 * Inside the loop, you should print the value of x, subtract 1 from x, and divide y by 2.
 * The loop should terminate when either x or y becomes negative.
 * Your task is to complete the code by filling in the missing parts.
 */
fun whileLoopAndOperator(x: Int, y: Int) {
/**
 * This exercise is designed to test your knowledge of basic while loop syntax and the AND operator.
 * Your task is to write a while loop that iterates as long as both x and y are positive numbers.
 * Inside the loop, you should print the value of x, subtract 1 from x, and divide y by 2.
 * The loop should terminate when either x or y becomes negative.
 * Your task is to complete the code by filling in the missing parts.
 */
fun whileLoopAndOperator(x: Int, y: Int) {

    var xValue = x
    var yValue = y

    // Start the loop
    while (xValue > 0 && yValue > 0) {
        // Print the value of x
        println(xValue)
        // Subtract 1 from x
        xValue--
        // Divide y by 2
        yValue /= 2

        // Add your code here

    }
    // End of loop
}