title: Autocomplete jQuery Plugin : Value of selected array index
body: <p>How do I get the value of the index position in the array, whose element the user had chosen using the autocomplete?</p>
  
  <p>For e.g. if I enter the array having two elements as the input for the autocomplete plugin:</p>
  
  <pre><code>var arr = [];
  arr[0] = "John";
  arr[1] = "Paul";
  </code></pre>
  
  <p>Then, say user selects "Paul", how do I get the value of the selected index "1"?</p>