title: jQuery onchange select option
body: <p>Let's say I have this HTML:</p>
  
  <pre><code>&lt;select id='list'&gt;
      &lt;option value='1'&gt;First&lt;/option&gt;
      &lt;option value='2'&gt;Second&lt;/option&gt;
      &lt;option value='3'&gt;Third &lt;/option&gt;
  &lt;/select&gt; 
  &lt;input type ="text" id="text"/&gt;
  </code></pre>
  
  <p>and then this JavaScript</p>
  
  <pre><code> //other variables are also declared here
      var x1 = 5;
      var x2 = 10;
      var value = x1 * x2;
      var list_value =$("#list").change(function() {
               $(this).val();
   // just an example of how i want the function in the variable 
      });
      var nwval = value * list_value;
        $('#text').val(nwval);
  // some long piece of code 
  // i'm also using the list_value value somewhere in the long piece of code..
  </code></pre>
  
  <p>I want the val in the textbox to change as the user selects an option, I know it'll work if I wrap the change event around it, but is there any way to go about this while keeping it as that variable <code>list_value</code>?</p>