Contents

Which statement is used when if block is skipped and other else block of code is executed?
a) if statement                     
b) if-else statement
c) nested if                           
d) switch statement

b

Which statement is used to select a block of statement is based on the value or variable?
a) if statement                     
b) if-else statement
c) nested if                           
d) switch statement

d

if there is no match the default block of variable is executed is called……
a) if statement                     
b) if-else statement
c) nested if                           
d) switch statement

d

Which symbol is used for writing a statement after condition?
a) {}       
b) []                        
c) ()                        
d) <>

a

The conditional operator is also known as
a) relational operator
b) binary operator
c) ternary operator 
d) chary operator

c

Explanation: Ternary operator that works with more than two vales


Which of the following keyword is used followed by case statement?
a) colon(:)                            
b) semicolon(;)
c) comma(,)                         
d) equal (=)

a