Question: 1. Below are statements in a SAS data step. What will the values be for sub1 and sub2 after execution? string= & Bob & Carol


1.


Below are statements in a SAS data step. What will the values be for sub1 and sub2 after execution? string= "& Bob & Carol & Ted & Alice & Leonardo"; sub1= scan(string, 1); sub2= scan(string, -2); O sub1=1, sub2=& O sub1=2, sub2=Alice sub1=1, sub2=Alice O sub1=Bob, sub2=AliceBelow are statements in a SAS data step. What will the values be for sub1 and sub2 after execution? string= "& Bob & Carol & Ted & Alice & Leonardo"; sub1= index(string, "Bob"); sub2= scan(string, -2); O sub1=1, sub2=Alice O sub1=2, sub2=Alice O sub1=1, sub2=& sub1=3, sub2=Alice
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
