Fun & Games

Fortune Cookie Generator

Draw a fortune and a set of lucky numbers, reproducible from a seed.

Last updated · View algorithm, constants and default inputs (JSON)

About this calculator

A fortune cookie is a random draw dressed up as advice, so the honest version is explicitly seeded: the same seed gives the same fortune and the same lucky numbers. Change the seed for a new draw.

Worked example

calculated with the default values below

Seed 77 · Lucky numbers up to 49 Your fortune Patience now buys speed later. · Lucky numbers 3, 6, 24, 35, 41, 44 · Lucky numbers drawn 6 · Fortune theme Courage

Disclaimer

These calculators give general estimates for information and entertainment. Platform algorithms, metrics and definitions change without notice, and none of these results are official figures from the platforms named.

Maintained by: CalcDelta

Implementation source

This record describes the implementation used by this page. It is not independent validation. External references, when available, support only the stated formula or definition; estimates and custom rules retain their own assumptions.

View algorithm, constants and default inputs (JSON)

Formula and variables

a_k = (a_{k-1} + 0x6D2B79F5) mod 2^32 -> u_k = g(a_k), u_k ∈ [0,1); i = floor(u_1 x 10) mod 10; v_k = 1 + floor(u_k x M)

s
seed (integer)
M
max lucky number
a_k
PRNG state
u_k
uniform value in [0,1)
i
fortune index (0-9)
v_k
drawn lucky number
g
state-to-[0,1) mapping

Deterministic PRNG (mulberry32-style) seeded with floor(s). The fortune text and theme come from a 10-entry table at index i. Lucky numbers are drawn without replacement until 6 distinct values are collected (or 500 attempts), then sorted ascending; M >= 6 is needed for six numbers.

Embed this calculator

Copy the iframe snippet to place this calculator on your site. No account required. The snippet stays in sync with the inputs currently shown.

Frequently asked questions

How can I get the same fortune again?

Use the same seed and the same maximum lucky number. The seed makes the generated fortune and number set repeatable in this calculator.

Are the fortune and lucky numbers predictions?

No. They are generated for entertainment and do not predict events or improve the odds of a game of chance.