  We report on the realization and application of non-destructive three-qubit
parity measurements on nuclear spin qubits in diamond. We use high-fidelity
quantum logic to map the parity of the joint state of three nuclear spin qubits
onto an electronic spin qubit that acts as an ancilla, followed by single-shot
non-destructive readout of the ancilla combined with an electron spin echo to
ensure outcome-independent evolution of the nuclear spins. Through the
sequential application of three such parity measurements, we demonstrate the
generation of genuine multipartite entangled states out of the maximally mixed
state. Furthermore, we implement a single-shot version of the GHZ experiment
that can generate a quantum versus classical contradiction in each run.
Finally, we test a state-independent non-contextuality inequality in eight
dimensions. The techniques and insights developed here are relevant for
fundamental tests as well as for quantum information protocols such as quantum
error correction.
