The following SAS program is submitted:
data WORK.COMPRESS;
ID = "˜1968 05-10 567';
NewID = compress (ID, "-");
run;
What will the value of NewID be in the WORK.COMPRESS data set?
The following SAS program is submitted:
data WORK.COMPRESS;
ID = "˜1968 05-10 567';
NewID = compress (ID, "-");
run;
What will the value of NewID be in the WORK.COMPRESS data set?
The SAS compress function removes specific characters from a string. In this case, the second argument is '-', meaning all hyphens will be removed from the string '1968 05-10 567'. Hence, the value of NewID will be '19680510567'.
the answer should be D.
in question it is given ID = "˜1968 05-10 567' with improper quotations. so may be Answer is =option 'A' , if it is correct quotations then answer will be option = 'D';
Answer is D .. Tested