If I set a varable how do I use it in the value of an object:

Ex:
var x = 3

<input name=text1 value=x + 2>

Thank you