1.Q41 Given the raw data record in the file phone.txt:
----|----10—|----20—|----30—|
Stevens James SALES 304-923-3721 14
The following SAS program is submitted:
data WORK.PHONES;
infile 'phone.txt';
input EmpLName $ EmpFName $ Dept $ Phone $ Extension;
<_insert_code_>
run;
Which SAS statement completes the program and results in a value of “James Stevens” for the variable FullName?
A. FullName=CATX(’ ‘,EmpFName,EmpLName);
B. FullName=CAT(’ ',EmpFName,EmpLName);
C. FullName=EmpFName!!EmpLName;
D. FullName=EmpFName + EmpLName;
本题知识点:
CAT系列函数
cat(of x1-x4):即x1||x2||x3||x4 catt(of x1-x4):即trim(x1)||trim(x2)||trim(x3)||trim(x4)
cats(of x1-x4):即trim(left(x1))||trim(left(x2))||trim(left(x3))||trim(left(x4))
catx(sp,of x1-x4):即trim(left(x1))||sp||trim(left(x2))||sp||trim(left(x3))||sp||trim(left(x