title: Dynamically Select Variable
body: <p>I have 2 variables like so</p>
  
  <pre><code>var variable_1 = "foo";
  var variable_2 = "bar";
  </code></pre>
  
  <p>I use a function to grab the value of a checkbox input and for each checkbox which is checked, I want to load the particular variable which depends on value of checkbox.</p>
  
  <pre><code>$("input:checked").each(function() {
      $(div).append('variable_'+$(this).val());
  }
  </code></pre>
  
  <p>So I'd concatenate the text 'variable_' with the value of each checkbox.</p>
  
  <p>Thanks!</p>