A SAS date value is
the number of days from January 1, 1960, to the given date.
Correct answer: d
In addition to tracking
time intervals, SAS date and time values can be used in calculations
like other numeric values. This lets you calculate values that involve
dates much more easily than in other programming languages.
Correct answer: b
SAS automatically makes
adjustments for leap years.
Correct answer: d
The SAS informat MMDDYYw.
reads dates such as 10222001, 10/22/01, or 10-22-01. In this case,
the field width is eight.
Correct answer: b
The minimum acceptable
field width for the TIMEw. informat is five. If you specify a w value
less than five, you will receive an error message in the SAS log.
Correct answer: d
In the time value of
a date and time expression, you must use delimiters to separate the
values for hour, minutes, and seconds.
Correct answer: c
The value of the YEARCUTOFF=
system option does not affect four-digit year values. Four-digit values
are always read correctly.
Correct answer: c
The w value
of the informat MMDDYY8. is too small to read the entire value, so
the last two digits of the year are truncated. The last two digits
thus become 19 instead of 25. Because the YEARCUTOFF= system option
is set to 1920, SAS interprets this year as 2019. To avoid such errors,
be sure to specify an informat that is wide enough for your date expressions.
Correct answer: b
To find the number of
days spanned by two dates, subtract the first day from the last day
and add one. Because SAS date values are numeric values, they can
easily be used in calculations.