Select the best answer
for each question. Check your answers using the answer key in the
appendix.
-
SAS date values are
the number of days since which date?
-
What is an advantage
of storing dates and times as SAS numeric date and time values?
-
They can easily be edited.
-
They can easily be read
and understood.
-
They can be used in
text strings like other character values.
-
They can be used in
calculations like other numeric values.
-
SAS does not automatically
make adjustments for daylight saving time, but it does make adjustments
for which one of the following?
-
An input data file has
date expressions in the form 10222001. Which SAS informat should you
use to read these dates?
-
What is the minimum
width of the TIMEw. informat?
-
Shown below are date
and time expressions and corresponding SAS datetime informats. Which
date and time expression cannot be read by the informat that is shown
beside it?
-
30May2018:10:03:17.2
DATETIME20.
-
30May18 10:03:17.2 DATETIME18.
-
30May2018/10:03 DATETIME15.
-
30May2018/1003 DATETIME14.
-
Suppose your program
creates two variables from an input file. Both variables are stored
as SAS date values: FirstDay records the start of a billing cycle,
and LastDay records the end of that cycle. What would be the code
for calculating the total number of days in the cycle?
-
TotDays=lastday-firstday;
-
TotDays=lastday-firstday+1;
-
TotDays=lastday/firstday;
-
You cannot use date
values in calculations.