Version compl�te: jsB@nk » Calcul » Math » Fibonacci
URL: https://www.javascriptbank.com/fibonacci.html
Affiche les séquences de Fibonacci Numbers, inscrites par l'utilisateur. Attention: Ce processeur est très intensive, ne pas entrer dans un grand nombre.
Version compl�te: jsB@nk » Calcul » Math » Fibonacci
URL: https://www.javascriptbank.com/fibonacci.html
<SCRIPT LANGUAGE="JavaScript">// Julian Rivera Pineda ([email protected]) --><!-- Beginfunction f(n) {var s = 0;if(n == 0) return(s);if(n == 1) {s += 1;return(s);}else {return(f(n - 1) + f(n - 2)); }}function show(n) {var i;for(i = 0; i <= n; i++) {f1.s.value += " " + f(i); }}// End --></script><!-- This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->
<form name=f1>Computations: <input type=text size=4 name="n"> <input type=button value="Compute" onClick="show(f1.n.value);"> <input type=reset value="Reset"><br>Sequence: <input type=text size="70" name="s"></form><!-- This script downloaded from www.JavaScriptBank.com Come to view and download over 2000+ free javascript at www.JavaScriptBank.com-->