this post was submitted on 20 Jan 2024
0 points (NaN% liked)

xkcd

8766 readers
147 users here now

A community for a webcomic of romance, sarcasm, math, and language.

founded 1 year ago
MODERATORS
 

cross-posted from: https://programming.dev/post/8677292


Transcript:

[A computer program.]

int getRandomNumber()
{
   return 4; // chosen by fair dice roll.
             // guaranteed to be random.
}

Hover Text:

RFC 1149.5 specifies 4 as the standard IEEE-vetted random number.

top 3 comments
sorted by: hot top controversial new old
[–] Thorry84@feddit.nl 0 points 9 months ago (1 children)

Just update the code once a year to a different number, given long enough time the output will have a perfectly flat distribution.

[–] veroxii@aussie.zone 0 points 9 months ago (1 children)

I mean, how many random numbers can there even be?

[–] cron@feddit.de 0 points 9 months ago

Not more than six, at least if you use a standard dice.