This is not ordinary code. A qubit holds a blend of possibilities — amplitudes you can see below. Measuring turns a blend into one definite answer. New here? Start with the Tutorial.

Qubble

1
seed shots

Circuit — the light-paths

add:

Guide

The state — amplitudes & phase

Press Run or Step to light up the amplitudes.
Each bar is a possibility; its height is how likely, its color & arrow are its phase. Bars that line up add; opposite phases cancel.

Output


    

Run ×N — the distribution

Add a measure (or a histogram) and press Run ×N to sample many runs.