The following SAS program is submitted:
proc format;
value score 1 - 50 = 'Fail'
51 - 100 = 'Pass';
run;
proc report data = work.courses nowd;
column exam;
define exam / display format = score.;
run;
The variable EXAM has a value of 50.5.
How will the EXAM variable value be displayed in the REPORT procedure output?
A. Fail
B. Pass
C. 50.5
D. . (missing numeric value)
Click Comment link to get answer
C
ReplyDeleteC
ReplyDeletec
ReplyDeleteAnswer is D. Tried a program on it, and the value that wasnt covered in the format was represented by a *
ReplyDeletec
ReplyDeletecan anybody tell me where is correct answer written
ReplyDeletecan anybody tell me where is correct answer written
ReplyDeleteYou have to try the question on your own, check and see what others have answered if that helps. Answers are not given on purpose, so that people will try to find the right answer.
ReplyDeleteSorry,but when you take the test, there is no SAS software provided. SO that is why someone need the specific explanation of the answer. If you do not know how it is worked by the theory, please do not show off. No offence.
DeleteAnswer is 50.5
ReplyDeleteBcause that value in between Fail(<50) and Pass(>51) Conditions
answer is D, to work, it should be 1 -< 51 and 51 -< 100
ReplyDeletetry it and you see
Regards,
daniel (from Brazil)
but that is not what the problem says so the answer is c.
Deleteyou MUST answer without changing the question.
Deleteanswer is C.
Answer is C.
ReplyDeleteAnswer is 'C'
ReplyDeleteTried the program and got the value of exam as 50.5
The Result is 'C' 50.5, Ex:Code is below.... You can run and see
ReplyDeletedata courses;
infile datalines;
input Result;
datalines;
20
35
51
50.5
75
100
;
run;
proc format;
value score 1 - 50 = 'Fail'
51 - 100 = 'Pass';
run;
proc report data = courses nowd;
column result;
define result / display format = score.;
run;
Great
DeleteCorrect answer is C, try this ..
ReplyDeleteproc format;
value score 1 - 50 = 'Fail'
51 - 100 = 'Pass';
run;
data courses;
exam = 50.5;
run;
proc report data = work.courses nowd;
column exam;
define exam / display format = score.;
run;
Ans is C.
ReplyDeleteIf you want 50.5 to be termed as a 'Pass' then use 1-<50 for 'Fail' and 50-100 for 'Pass'
Sakar;
ReplyDeleteWho ever said D, ask yourself where 50.5 fits? in fail or pass category?
I believe that as format score written here which is responsible for the result 50.5. As when we format any statement we mention format profit dollar 9.2.
ReplyDeleteD
ReplyDeleteThe correct answer is C, just run the program;
ReplyDeleteproc format;
value score
1 - 50 = 'Fail'
51 - 100 = 'Pass';
run;
data courses;
input exam;
cards;
50.5
;
run;
proc report data = work.courses nowd;
column exam;
define exam / display format = score.;
run;
Answer C:
ReplyDeletethe program does not show any user defined format for 50.5. Therefore that value will just stay as is.
Answer C
ReplyDeletedata courses;
input Name $ Exam;
datalines;
Blank 50.5
test1 54
test2 48
;
proc format;
value score 1 - 50 = 'Fail'
51 - 100 = 'Pass';
run;
proc report data = work.courses nowd;
column exam;
define exam / display format = score.;
run;
When a format does not apply to a value, the value remains the same. no change happens to variable Exam and hence the value will be 50.5
ReplyDeleteGood explanation. Thanks.
Deleteif you wanna join casino online. Thank you
ReplyDeletegclub online
goldenslot
ANS IS C
ReplyDeleteC
ReplyDelete