Multiple choice technology programming languages

data str; x='My name is myuri'; a=find(X,'MY','i',-3); run; What is the value of a?

  1. 1

  2. 12

  3. 10

  4. 2

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The FIND function searches for 'MY' within 'My name is myuri'. The third parameter 'i' makes the search case-insensitive. The -1 indicates searching from the end of the string. FIND finds 'MY' starting at position 1 (the 'My' at the beginning) and returns the starting position. The case-insensitive modifier allows it to match 'My' even though we're searching for 'MY'.