nerdexam
SAS_Institute

A00-280 · Question #72

The following SAS program is submitted: ``sas data WORK.DATE_INFO; X='04JUL12:03:'; DayofMonth=day(x); MonthofYear=month(x); Year=year(x); run; `` Which types of variables are DayofMonth…

The correct answer is B. DayofMonth, Year, and MonthofYear are numeric. See the full explanation below for the reasoning.

Question

The following SAS program is submitted:
data WORK.DATE_INFO;
 X='04JUL12:03:';
 DayofMonth=day(x);
 MonthofYear=month(x);
 Year=year(x);
run;
Which types of variables are DayofMonth, MonthofYear, and Year?

Options

  • ADayofMonth, Year, and MonthofYear are character.
  • BDayofMonth, Year, and MonthofYear are numeric.
  • CDayofMonth and Year are numeric. MonthofYear is character
  • DDayofMonth, Year, and MonthofYear are date values

How the community answered

(24 responses)
  • A
    4% (1)
  • B
    83% (20)
  • C
    4% (1)
  • D
    8% (2)

Community Discussion

No community discussion yet for this question.

Full A00-280 Practice