title: use eval to evaluate a javascript snippet in a textarea?
body: <p>I'm at my first hackathon and trying to finish my project. I am very very new the javascript... everything I know I literally learned in the last 2 hours. That being said...</p>
  
  <p>So I know that eval is not the greatest thing to use, but I'm trying to write a simple program in which you can input a javascript snippet into a textarea, click an execute button, and have the javascript execute inside another textarea. I'm trying to stay away from jquery for now, because I want to get the really basic idea down before I add another level of complexity, which is why I'm not using id's.... but if jquery is the only way to do this, then I guess I'll have to pony up and learn it in the next 8 hours.</p>
  
  <p>Code as follows (ish):</p>
  
  <pre><code>function executeJS ()
  {
      var result = eval(game.input.value);
      game.execute.value=result;
  }
  &lt;head&gt;
      &lt;body&gt;
      &lt;H1&gt;PRogram&lt;/H1&gt;
              &lt;form name="game"&gt; 
  
              &lt;textarea name="execute" rows="5" cols="30" value=""&gt;&lt;/textarea&gt;&lt;br&gt;
              &lt;textarea type="text" name="input" rows="10" cols="30" value=""&gt;&lt;/textarea&gt;
  
              &lt;input type = "button" value = "guess" onclick = "executeJS()&lt;/input&gt;
              &lt;/form&gt;
      &lt;/body&gt;
  &lt;/head&gt;
  </code></pre>
  
  <p>I'm not getting an output in my execute box.</p>
  
  <p>Any insight would be much appreciated.</p>