2 releases

0.1.1 Jul 13, 2022
0.1.0 Jul 13, 2022

#305 in Simulation

MIT/Apache

18KB
472 lines

// Create a bell state, or EPR pair, a superposition of qubits 0 and 1
let mut state = State::new(2);
state.h(0);
state.cx(0, 1);
state.measure(1);

println!("{state}");
println!("{}", state.ket());

Dependencies

~315KB