topic/Conditional Statements
Start Test
Question No
Title
Type
Marks
407.
What is the purpose of theifstatement?
MCQ
5
408.
Which keyword is used to introduce theelseblock in anif-elsestatement?
MCQ
5
409.
What will be the output of the following code?x = 10 y = 5 if x > y: print("x is greater") else: print("y is greater")
MCQ
5
410.
Which of the following is the correct syntax for anifstatement with multiple conditions?
MCQ
5
411.
What will happen if the following code is executed?temperature = 25 if temperature > 30: print("It's hot!") elif temperature > 20: print("It's warm.") else: print("It's cool.")
MCQ
5