Exam A00-211 All QuestionsBrowse all questions from this exam
Question 7

The following SAS program is submitted:

data work.sets;

do until (prod gt 6);

prod + 1;

end;

run;

What is the value of the variable PROD in the output data set?

    Correct Answer: B

    In the provided SAS program, a DO UNTIL loop is used, which will continue executing until the condition (prod > 6) is met. Initially, the variable PROD is implicitly set to 0. The loop increments PROD by 1 in each iteration. The loop will execute as long as PROD is less than or equal to 6. The looping stops when PROD becomes 7 after it is incremented from 6. Hence, the final value of the variable PROD in the output data set is 7.

Discussion
Mouni_18Option: B

B is correct.