XKCD | Website February 9, 2007

Alt Text

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

Transcript
int getRandomNumber()
{
	return 4;	//chosen by fair dice roll.
					// guaranteed to be random.
}
  • abbadon420@sh.itjust.works
    link
    fedilink
    arrow-up
    1
    ·
    15 days ago

    The prophet has spoken. The holy scripture has once again proven itself. What more do you non-believers need? All hail xkcd!

  • thehatfox@lemmy.world
    link
    fedilink
    English
    arrow-up
    1
    ·
    15 days ago

    The mistake was to pre-roll the dice. Security could have been greatly improved by providing the randomness as a service, with the developer being paid a monthly fee to roll the dice for each function call.