Question 64 :

 The following SAS program is submitted:

 data work.new;

 length word $7;

 amount = 7;

 if amount = 5 then word = 'CAT';

 else if amount = 7 then word = 'DOG';

 else word = 'NONE!!!';

 amount = 5;

 run;

 Which one of the following represents the values of the AMOUNT and WORD variables?

 

  1. amount word

 5 DOG

  1. Get all Questions and Answer from here
  2. You need to have paid subscription to access all questions
  3. Thanks for considering SAS Certification Material

 Correct Answer : 1

 Exp : always "Dog" will be assigned to word as amount is hardcoded 7 in the begining of each iteration

 and a value of 5 is saved in amount as it is hardcoded before the end of each output.

You can access to full explanation to question and answer from this page.