Pseudo-random numbers/Xorshift star: Difference between revisions
Content added Content deleted
(Add Factor) |
m (→{{header|Factor}}: make it return a float instead of a ratio) |
||
Line 103: | Line 103: | ||
state<< const * mask64 bitand -32 shift mask32 bitand ; |
state<< const * mask64 bitand -32 shift mask32 bitand ; |
||
: next-float ( obj -- |
: next-float ( obj -- x ) next-int 1 32 shift /f ; |
||
! ---=== Task ===--- |
! ---=== Task ===--- |