title: recursive function to locate last occurence of an element
body: <p>I am trying to write a recursive function in C,</p>
  
  <p>Given an array, size of the array as well as the element int target, I want to find the index of int target's last occurence. </p>
  
  <pre><code>#include &lt;stdio.h&gt;
  int rLookupAr(int array[], int size, int target);
  int main()
  {
     int numArray[80];
     int target, i, size;
  
     printf("Enter array size: \n");
     scanf("%d", &amp;size);
     printf("Enter %d numbers: \n", size);      
     for (i=0; i &lt; size; i++)
        scanf("%d", &amp;numArray[i]);
     printf("Enter the target number: \n");
     scanf("%d", &amp;target);
     printf("rLookupAr(): %d", rLookupAr(numArray, size, target));
     return 0;
  }
  int rLookupAr(int array[], int size, int target)
    {
    }
  </code></pre>
  
  <p>However, I have been stuck for hours. </p>
  
  <p>I am a beginner to recursive functions and any help will be greatly appreciated!</p>
  
  <p>Some examples:</p>
  
  <pre><code>Enter array size:
  5
  Enter 5 numbers:
  2 1 3 2 4
  Enter the target number:
  2
  rLookupAr(): 3
  </code></pre>