Author: | otoburb |
---|---|
Mode: | factor |
Date: | Thu, 30 Aug 2012 01:59:09 |
:: ((random-integer)) ( bits obj -- n required-bits ) obj random-32* 32 bits 32 - [ dup 0 > ] [ [ 32 shift obj random-32* + ] [ 32 + ] [ 32 - ] tri* ] while drop ;
Author: | otoburb |
---|---|
Mode: | factor |
Date: | Thu, 30 Aug 2012 02:04:16 |
: ((random-integer)) ( num-bits obj -- n ) random-32* swap bits ;