Which of the following PL/I SELECT statements is correct ?

  1. SELECT (A); WHEN (A=0) PUT LIST(‘A = 0‘); WHEN (A=5) PUT LIST (‘A = 5‘); OTHERWISE PUT LIST (‘A IS NOT 0 NOR 5’); END;

  2. SELECT (A); WHEN (0) PUT LIST(‘A = 0‘); WHEN (5) PUT LIST (‘A = 5‘); OTHERWISE PUT LIST (‘A IS NOT 0 NOR 5’); END;

  3. SELECT; WHEN (A=0) PUT LIST(‘A = 0‘); WHEN (5) PUT LIST (‘A = 5‘); OTHERWISE PUT LIST (‘A IS NOT 0 NOR 5’); END;

  4. All of the above


Correct Option: B

Find more quizzes: