1.
The elsif statement can add many alternatives to if/else statements.
A
True
B
False
View Answer
Correct Answer: A — True
Explanation:
We can add many conditions between if/else statements using elsif conditional statement.
3 practice sets · Page 1 of 1
The elsif statement can add many alternatives to if/else statements.
True
False
Correct Answer: A — True
Explanation:
We can add many conditions between if/else statements using elsif conditional statement.
The elsif conditional statement is written with an expression.
True
False
Correct Answer: A — True
Explanation:
The syntax of elsif conditional statement is elsif with an expression.
Which of the following is valid conditional statement in Ruby?
elseif
elsif
else if
elseiff
Correct Answer: B — elsif
Explanation:
We use elsif conditional statement in Ruby.