The following code reason doesn't make sense.
If x = 41 and I check if its greater than 10 and 20, why would I print out "but not above 20." x is greater than 20 and it's greater than 30 and 40 as well.
Perhaps w3schools could use a better example for beginners to make it more clear.
You can have if statements inside if statements, this is called nested if statements.
x = 41 if x > 10:
if x > 20:
print("and also above 20!")
print("but not above 20.")