What is the code to take an input from a form and assign it to a variable? Such as the in the form below with input "first".

Also, how do I display the result of a math operation back to the "result" value of the form?

<form name = "comparison" action = "">
<table border = "1">
<caption>Integer Comparison</caption>
<tr><td>Input First Integer</td>
<td><input name = "first" type = "text" />
<tr><td>Input Second Integer</td>
<td><input name = "second" type = "text" />
<tr><td><input type = "button" value = "Compare Inputs"
onclick = "comparison()" /></td></tr>

<tr><td>The First Integer is/td>
<td><input name = "result" type = "text" /></td></tr>