Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Random Numbers in Bash. Parent comment
AFAIK it's the true source of randomness in any unix.
> I’m not sure the best way to make use of it as a source of random decimals — there are surely a dozen ways to do so — but this works:
`od(1)` will do binary to binary to decimal:
> head -c4 /dev/urandom | od -An -vtu4 4119929390 > head -c4 /dev/urandom | od -An -vtu4 3540752584 > head -c4 /dev/urandom | od -An -vtu4 998126897
There are no comments on this comment yet.
AFAIK it's the true source of randomness in any unix.
> I’m not sure the best way to make use of it as a source of random decimals — there are surely a dozen ways to do so — but this works:
`od(1)` will do binary to binary to decimal: