SAS_Institute
A00-212 · Question #156
A00-212 Question #156: Real Exam Question with Answer & Explanation
The correct answer is C. ptobs = ceil(ranuni(0) * totobs);. See the full explanation below for the reasoning.
Question
The variable TOTOBS has a value of 123, which represents the total number of observations in a SAS data set. Which assignment statement correctly creates the variable PTOBS that guarantees a valid observation number in that SAS data set?
Options
- Aptobs = ranuni(0) * totobs;
- Bptobs = int(ranuni(0) * totobs);
- Cptobs = ceil(ranuni(0) * totobs);
- Dptobs = floor(ranuni(0) * totobs);
Community Discussion
No community discussion yet for this question.