 To have more interesting condition expressions, we need a few more operators. First there's the less than operator, which returns true when its operands, which almost be numbers, increase in value from left to right. So the first example here returns true because 25 is less than 76, and 76 is less than 8,000. But then the second example returns false because 35 is not less than negative 2, and the third example also returns false because 2 is not less than 2. A similar operator is less than or equal, which we write LTE. And the last example here would be write LTE 227 that returns true because 2 is less than or equal to 2. And then as you might imagine, we have the reverse of less than, we have greater than, which returns true when its operands decrease in value from left to right. So the first example here, GT 25 76 8000 returns false because 25 is not greater than 76, nor the greater than 8,000. And the second example returns true because 35 is greater than negative 2, which in turn is greater than negative 10. And the last example returns false because, yes, 8 is greater than 4, but 4 is not greater than 4. If we use the greater than or equal operator instead, written GTE, then this last example returns true because 8 is greater than 4 and 4 is equal to 4. The AND operator takes two or more Boolean operands and returns true only when all of those Boolean values are true. So the first example here returns true, but all the remaining examples return false. The OR operator also takes two or more Boolean operands, but returns true when just at least one of the operands is true, not necessarily all. So the first three of these examples return true because at least one of the operands is true or all of them are true, but then the last example returns false because the operands are all false. The modulus operator, written mod, returns the remainder of division. So for example, mod 15 5, 15 divided by 5 is 3, where the remainder is 0, so this returns 0, but 16 divided by 5 is 3, where the remainder of 1, so 16 mod 3 returns 1. And mod 17 5 returns true because 17 divided by 5 is 3, with the remainder of 2. One useful thing to do with the mod operator is to test whether a number is even or odd. Here when we write mod x2, when x is an even number, mod x2 will return 0. So here in this code, when x is even, mod x2 returns 0, and yes, 0 is equal to 0, so the condition of the if is true, and the code prints even. Otherwise when x is odd, mod x2 will return 1, and 1 is not equal to 0, so the condition will test false, and the code prints odd. Often in code, we want what's called a loop. That is, we want a section of code that repeats some number of times. For this purpose, we have the while statement. A while statement looks very much like an if, with a condition and a body, but with a reserved word while in place of if. The word while was chosen because a while loop has a sense of do this stuff while this condition is true. The way while works is that just like an if, the condition is evaluated and when it's true, the body is executed. The difference is that once the body is done executing, the condition is tested again, and when the condition is once again true, the body is executed again. This happens ad infinitum until the condition tests false, at which point the body is skipped over and execution continues on past the while. So consider what this code does. First we assign 6 to a variable named z, and then we encounter a while loop where the condition asks is z greater than 0. Currently, z has the value 6, so yes it is greater than 0, so this returns true, and we execute the body, which prints the value of z which is currently 6, and then assigns to z the value of z minus 1. z minus 1 is 5, so we assign 5 to z. And now that the run through the while body is finished, the condition is tested again, and the value of z is still greater than 0, so the body is executed again, the value 5 gets printed, and z is assigned 1 less than 5, the value 4, before the condition is tested again. And this process continues like this until, in the last iteration of the loop, z is assigned 0, and so the condition will test false because 0 is not greater than 0, ending execution of the loop. In effect, this code ends up printing the value 6, then 5, then 4, then 3, then 2, then 1. The body of this loop ends up running 6 times.