title: Get object from array by specifc index using variable
body: <p>I have 1 variable and 1 array. The array contains any number of numbers, from 0 to 10 - like such: 0,1,2,3,4,5 and so on.</p>
  
  <p>My variable contains 1 number, let's say 4 - I want to use the variable to get the number at index 4 in the array, minus 1. So in the above examples, I would get 2.</p>
  
  <p>How can I go about creating a variable with that number? I have tried:</p>
  
  <pre><code>var goBack = $(userBack2).index(place-1);
  </code></pre>
  
  <p>Where <strong><em><code>goBack</code></em></strong> is the variable I am creating, <strong><em><code>userBack2</code></em></strong> is the array containing my numbers and <strong><em><code>place</code></em></strong> is my variable determining what index I need.</p>
  
  <p>I know that the syntax is completely wrong, that index might not be correct to use here, but I simply cannot figure out how to do it. Do I need to use filter? if so, how?</p>