SAS Certified Base Programmer 123 Questions (41)
The following SAS program is submitted:
proc datasets lib = sasuser; contents data = class varnum; quit;
Which one of the following is the purpose of the VARNUM option?
A. to print a list of variable names
B. to print the total number of variables
C. to print a list of the variables in alphabetic order
D. to print a list of the variables in the order they were created
SAS Certified Base Programmer 123 Questions (40)
The following SAS program is submitted:
proc contents data = sasuser.airplanes; run;
Which one of the following is produced as output?
A. the data portion of every data set in the SASUSER library
B. the data portion of the data set SASUSER.AIRPLANES only
C. the descriptor portion of every data set in the SASUSER library
D. the descriptor portion of the data set SASUSER.AIRPLANES only
SAS Certified Base Programmer 123 Questions (39)
A raw data file is listed below:
----|----10---|----20---|----30 John McCloskey 35 71 June Rosesette 10 43 TinekeJones 9 37
The following SAS program is submitted using the raw data file as input:
data work.homework; infile 'file-specification'; input name $ age height; if age LE 10; run;
How many observations will the WORK.HOMEWORK data set contain?
A. 0
B. 2
C. 3
D. No data set is created as the program fails to execute due to errors.
SAS Certified Base Programmer 123 Questions (38)
The SASDATA.BANKS data set has five observations when the following SAS program is submitted:
libnamesasdata 'SAS-date-library'; data allobs; set sasdata.banks; capital=0; do year = 2000 to 2020 by 5; capital + ((capital+2000) * rate); output; end;
How many observations will the ALLOBS data set contain?
A. 5
B. 15
C. 20
D. 25
SAS Certified Base Programmer 123 Questions (37)
The SAS data set named COMPANY.PRICES is listed below:
COMPANY.PRICES
prodid | price | producttype | sales | returns |
K12S | 5.10 | NETWORK | 15 | 2 |
B132S | 2.34 | HARDWARE | 300 | 10 |
R18KY2 | 1.29 | SOFTWARE | 25 | 5 |
3KL8BY | 6.37 | HARDWARE | 125 | 15 |
DY65DW | 5.60 | HARDWARE | 45 | 5 |
DGTY23 | 4.55 | HARDWARE | 67 | 2 |
The following SAS program is submitted:
libnamecompany 'SAS-data-library'; data hware inter soft; set company.prices (keep = producttype price); if price le 5.00; if producttype = 'HARDWARE' then output HWARE; else if producttype = 'NETWORK' then output INTER; else if producttype = 'SOFTWARE' then output SOFT; run;
How many observations does the HWARE data set contain?
A. 0
B. 2
C. 4
D. 6