#JavaScript (ES6), 33 28 25 24 bytes
JavaScript (ES6), 33 28 25 24 bytes
n=>g=(x=n)=>--x?n*g(x):n
##Try It
Try It
f=
n=>g=(x=n)=>--x?n*g(x):n
o.innerText=f(i.value=3)()
i.oninput=_=>o.innerText=f(+i.value)()
<input id=i min=1 type=number><pre id=o>
##History
###25 bytes
f=(n,x=n)=>--x?nf(n,x):n
###28 bytes
n=>eval(1+(""+n).repeat(n))
###33 bytes
n=>eval(Array(n).fill(n).join*
)
History
25 bytes
f=(n,x=n)=>--x?n*f(n,x):n
28 bytes
n=>eval(1+("*"+n).repeat(n))
33 bytes
n=>eval(Array(n).fill(n).join`*`)