Bits vs. Qubits: A Software Engineer’s Guide
Start with the smallest useful mental model: what changes when a two-state variable becomes a measurable quantum state?
A state-vector simulator with a nine-step course built into it. You place gates on graph paper, the state updates as you type, and each step only ticks off once your circuit actually does the thing.
Read a small idea, build it in the lab, inspect what changed, then see the equivalent code. You do not need physics before you begin.
Open the next short tutorial and focus on one concept.
Follow the active task in the course rail and place the gates.
Compare the histogram, amplitudes, and Bloch sphere after each change.
Copy the generated Qiskit or PennyLane code and continue locally.
A practical reading path for software engineers. Start with the mental model, make the linear algebra executable, then choose a framework and build a hybrid ML system.
Translate familiar software ideas into quantum intuition.
02 · mathUse NumPy to make states, amplitudes, and operators tangible.
03 · toolsBuild the same ideas in Qiskit and PennyLane.
04 · capstoneConnect parametrized circuits to classical learning loops.
Beginner · no physics degree required
Start with the smallest useful mental model: what changes when a two-state variable becomes a measurable quantum state?
Model a qubit as data, not magic, and see why entanglement belongs to the pair rather than either object.
Follow a circuit from build to transpile to measurement, including the parts that disappear before hardware sees it.
Compare classical boolean logic with reversible quantum operations and learn why there is no quantum “erase”.
Intermediate · NumPy-first
Build vectors, matrices, and inner products from scratch without hiding the computation behind physics vocabulary.
Plot complex amplitudes, square their magnitudes, and connect a state vector to the outcomes a measurement can return.
Why multiplying a full 2ⁿ × 2ⁿ matrix is a useful teaching trick but a poor simulator architecture.
Intermediate · industry tools
Write, inspect, and measure the canonical two-qubit circuit while keeping the simulator mathematics visible.
See how a quantum node fits inside an autodiff workflow and why the parameter-shift rule matters.
A practical comparison based on the task: hardware control, circuit research, gradients, or hybrid machine learning.
Advanced · capstone
Understand trainable rotations, observables, loss functions, and the classical optimiser in a PQC loop.
Compare basis, angle, and amplitude encoding, including the trade-off that makes loading data the real bottleneck.
Design a small image classifier with classical feature extraction, a quantum layer, and an honest evaluation plan.
Drag a gate from the palette onto the paper, or tap a gate then tap a square. Click a placed gate to remove it. Everything recomputes on every change — there is no run button to forget.
A control dot plus a gate in the same column makes that gate controlled: ● + X is CNOT, ● + ● + X is Toffoli, ● + Z is CZ. Two × marks in one column swap those wires.
| basis | amplitude | prob | phase |
|---|
This updates as you build. Paste it into a notebook and you are running the identical circuit on a framework that can also target hardware.
Eight circuits worth knowing. Loading one drops it on the bench, where you can step through it column by column and take it apart.
There isn't one, on purpose. This simulator keeps the full state vector and measures once, at the end — which is what the histogram shows. Textbook circuits like teleportation appear to need a measurement in the middle, but the deferred measurement principle says any mid-circuit measurement can be pushed to the end if you replace the classically-controlled correction with a quantum-controlled one. The teleportation circuit below is written that way, and it gives identical statistics.
The nearest-term use of a quantum computer is chemistry: prepare a trial state, measure its energy, let a classical optimiser move the knob, repeat. The curve below is computed by the simulator on this page — one energy evaluation per point, using the same gate engine you have been dragging gates into.
The two-qubit Hamiltonian is H = g₀I + g₁Z₀ + g₂Z₁ + g₃Z₀Z₁ + g₄Y₀Y₁ + g₅X₀X₁, with coefficients from O'Malley et al., Phys. Rev. X 6, 031007 (2016) for H₂ at a 0.75 Å bond length in the STO-3G basis. The trial state is exp(−iθ X₀Y₁/2) applied to |01⟩. Each point on the curve is six Pauli expectation values read off the state vector, plus the nuclear repulsion term added back. The "exact" figure comes from diagonalising the same Hamiltonian by hand in the two-dimensional sector the ansatz lives in — so if those two numbers agree, the simulator is right.
Short list, all free, all checked. A toy simulator can show you what happens; these will tell you why.
An essay with spaced-repetition questions built into the page, so it tests you as you read. If you only read one thing, read this one.
Start with John Watrous's Basics of Quantum Information — it is the rigorous treatment, and it is genuinely well taught rather than a product tour.
Why the correlations you will produce in step 07 cannot be explained by the two qubits having agreed on an answer in advance.
The simulator this page learned from, and still the best one. Deeper, faster, and it shows a live readout on every wire at every column at once.
The best writing anywhere on variational circuits and quantum machine learning. Start with the VQE demo, which is the section above done properly.
Test-driven exercises: every task starts as a failing unit test and you write quantum code until it passes. Hard to fool yourself with these.
For when you want to run on real hardware and meet noise, transpilation and queue times for the first time.
The graduate course, free. The standard next step once Nielsen & Chuang stops being enough, especially on error correction.
Worth reading as much for what he debunks as for what he proves. The best antidote to quantum-computing press releases.
Course sequences from a group that builds the hardware, including a good one on the quantum internet that nobody else covers.
Every gate here is perfect and qubits never decohere. Real devices lose their state in microseconds, and roughly all of the current engineering effort goes into that problem. Nothing you build here will behave this cleanly on hardware.
Eight qubits means tracking 256 complex amplitudes on your CPU. Fifty qubits would need more memory than exists. That gap is the entire argument for building quantum computers, and you can feel it in the qubit dropdown.
The state is only measured once, at the end. Circuits that classically need a measurement in the middle are rewritten using the deferred measurement principle, which is exact but not how hardware runs them.
For anything real, use Qiskit or PennyLane. The point of this page is that you can see the state vector, which on a real machine you fundamentally cannot.