I am not sure what I am doing wrong, I need to read a variable from an input form (HTML), and, return its absolute value:

<title>Home page </title>
The brown fox jumps over the red wooden tree
function abs(x)
if (x >=0) {return x;]
else {return -x;}
<% number age = 0 %;>
First name: <input type="text" name="firstname"><br>
Last name: <input type="text" name="lastname">
Age: <input type="number" name="What is your age?" value="<%=age%>">
<button type="button" onclick="abs(age)">What's my age again?</button>