var n parseInt(window.prompt("input)); var mul = 1; for (var i = 1; i< = n; i++){ mul * = i; } document.write(mul);