title: How to iterate through an array whose variable name depends on a different variable
body: <p>I tried Google this, but it's hard to explain what I am trying to do.</p>
  
  <p>I am returned with a string <code>var returnedString = model one</code>. </p>
  
  <p>Suppose I have a bunch of arrays called </p>
  
  <pre><code>var model_one   = ['a', 'b', 'c']
  var model_two   = ['d', 'e', 'f']
  var model_three = ['f', 'g', 'h']
  </code></pre>
  
  <p>This is what I have done</p>
  
  <pre><code>var selectedArrayName = returnedString.replace(" ", "_") //model_one
  </code></pre>
  
  <p>And this is what I want to do... </p>
  
  <pre><code>for (i in array with name selectedArrayName) {
      print selectedArrayName's array index. 
  }  
  </code></pre>