Pseudo-random numbers/Middle-square method: Difference between revisions

m
Line 213:
=={{header|Amazing Hopper}}==
Flavour BASICO.
<p>Version 1:</p>
<syntaxhighlight lang="c">
#include <basico.h>
Line 233:
432883
</pre>
<p>Version 2:</p>
<syntaxhighlight lang="c">
#include <basico.h>
Line 241:
iterar grupo( --i, i, #( s = int(s ^2 / 1000 % 1000000) ) \
s, NL, imprimir )
terminar
</syntaxhighlight>
{{out}}
<pre>
idem.
</pre>
<p>Version 3:</p>
<syntaxhighlight lang="c">
#include <basico.h>
 
algoritmo
s=675248, i=5
iterar grupo( --i, i, #( int(s ^2 / 1000 % 1000000) ) \
---copiar en 's'---, NL, imprimir )
terminar
</syntaxhighlight>
543

edits