Real World Maths Busters

The Maths Behind Everyday Life

The story, the formula and a worked example — see exactly where this maths shows up in the world around you.

Back to all stories
Technology 4 min read

Why blockchains are almost impossible to fake

Finding two inputs with the same hash is like winning the lottery trillions of times in a row.

Cryptographic hash functions produce a fixed-length fingerprint for any input. For a 256-bit hash (like SHA-256), the number of possible outputs is so astronomical that a collision — two different inputs giving the same hash — is essentially impossible.

How many possible hashes?

A 256-bit hash has 22562^{256} possible outputs. That’s a number with 77 digits — more than the estimated atoms in the observable universe.

Outputs=2256≈1.16×1077\text{Outputs} = 2^{256} \approx 1.16 \times 10^{77}

Total possible 256-bit hashes

Birthday-attack threshold

Thanks to the birthday paradox, you’d expect a collision after about 2256=2128\sqrt{2^{256}} = 2^{128} tries.

Collision attempts needed

  1. 1

    Birthday bound

    2256=2128≈3.4×1038\sqrt{2^{256}} = 2^{128} \approx 3.4 \times 10^{38}
  2. 2

    Scale

    If you tried a billion hashes per second, it would take about 10 billion billion years — far longer than the age of the universe.

Answer

You’d need roughly 340 undecillion attempts to find a collision — SHA-256 is safe for the foreseeable future.

The formula behind it

Birthday Problem

n≈Nn \approx \sqrt{N}
See the full formula, variables and more examples

The takeaway

The security of blockchains, passwords, and digital signatures rests on the sheer size of hash spaces — 2 raised to the 256th power is a number beyond human intuition.

Back to all stories