Syneos Health Interview Question

give the r/sas code to this...