Quantum Builders ClubQuantum computing projects

Project 01 · Ladder 1 · Beginner

Quantum Coin Flip: your first quantum computing project

How it works

  1. A Hadamard gate puts one qubit in superposition: heads and tails at once.
  2. Measuring forces a choice. Every toss lands heads or tails, 50/50.
  3. Toss after toss the bars even out, and a chi-square test proves the coin fair.

Your first qubit. Your first circuit. Your first quantum repo on GitHub, this week.

Start my 7-day free trialSee all ten builds

Level
Beginner
Hours
2 to 4
Automated tests
18
Ships to
GitHub

What you build

Quantum Coin Flip in Python and Qiskit

You're about to write real quantum code. You'll put a qubit into superposition, measure it a thousand times, prove with statistics that your coin is fair, catch a rigged coin red-handed, and ship the whole thing as a tested GitHub repo an employer can open.

In October 2025 the Nobel Prize in Physics went to John Clarke, Michel Devoret and John Martinis for showing that an electric circuit on a chip can behave like a single quantum object. That discovery grew into the superconducting qubits inside IBM's and Google's quantum computers today. Tonight you write your first program for one, and on Day 30 you run this same coin on a real 156-qubit IBM quantum computer, on IBM's free plan.

It's small on purpose: the workflow you learn here (build a circuit, run it, read the results, test them) is the one every bigger quantum project uses, all the way up the ladder.

The quantum ideas inside

  • Qubits
  • Superposition
  • The Hadamard gate
  • Measurement
  • Chi-square tests
  • Qiskit Aer

New to Qiskit? Run your first circuit free, or warm up with the free Qiskit tutorials.

Real output · Project 01Qiskit Aer simulator

python quantum_coin.py --flips 1000 --seed 7
Your quantum coin circuit:
     ┌───┐┌─┐
  q: ┤ H ├┤M├
     └───┘└╥┘
c: 1/══════╩═
           0
First 20 quantum flips: TTHTTTTHTTHTTTHTHHTT
Quantum  : heads=486 tails=514 heads_fraction=0.486
Classical: heads=537 tails=463 heads_fraction=0.537
Chi-square vs fair coin: 0.784 (consistent with fair)
What your finished program prints, from the build's own guide.

By the end

What you walk away with

  • a working quantum coin on IBM's open-source Qiskit Aer simulator, fair or biased to any probability you choose
  • a classical coin to compare it against
  • a chart showing both coins settling towards 50/50
  • 18 automated tests that check fairness with real statistics
  • one extension that is yours alone
  • a public GitHub repo, a portfolio paragraph and a LinkedIn post

Where it sits

Ladder 1: Beginner

BeginnerLadder 1

  1. Quantum Coin Flip

    One qubit, proven fair with real statistics.

    18 tests · 2 to 4 hours

  2. Quantum Dice Roller

    Catch a loaded die red-handed.

    16 tests · 3 to 5 hours

  3. Quantum Random Number Generator

    Build it, then try to break it.

    18 tests · 4 to 6 hours

  4. Quantum Password Generator

    Its strength, measured in bits.

    17 tests · 4 to 6 hours

Your first circuit is 10 minutes away

Stop watching quantum. Start shipping it.

Start my 7-day free trial

$0 today. 7 days free, then $7.99 a week or $190 a year. Cancel any time.

Detail C · A qubit's state