<script> function a(n,x,k) { x = x * 1.3 + 300 * ++k; n--; return n <= 1 ? x : a(n,x,k) } ; for (var i=2; i<10; i++) {document.write(i + " = " +a(i,100,0 )+ "<br>")} </script>