Skip to content
Kartikey Purohit
← Course overview

Sample Papers

Paper 10 (full length)

Exam: IBM C1000-179 — Fundamentals of Quantum Computing Using Qiskit v2.X Developer Questions: 68 (single best answer unless marked "choose two") Time limit: 90 minutes (~79 seconds per question) Passing score: 47 / 68 (≈69%)

Rules for the rehearsal: closed book, no interpreter, no pausing the clock. Mark uncertain questions and return to them; an unanswered question is always wrong. All code assumes Qiskit v2.x with qiskit-ibm-runtime (V2 primitives) and the standard imports shown in each snippet. Bitstrings are little-endian: qubit 0 is the rightmost character.


Section 1 — Create Quantum Circuits (Q1–Q12)

Q1. A researcher benchmarks circuit metrics before submitting to hardware:

from qiskit import QuantumCircuit
qc = QuantumCircuit(3)
qc.h(0)
qc.cx(0, 1)
qc.cx(1, 2)
qc.barrier()
qc.measure_all()
print(qc.depth())

What is printed?

  • A. 3
  • B. 4
  • C. 5
  • D. 6

Q2. Two engineers build fragments of a workflow:

from qiskit import QuantumCircuit
a = QuantumCircuit(2)
a.h(0); a.cx(0, 1)
b = QuantumCircuit(2)
b.cx(0, 1); b.h(0)
c = a.compose(b.inverse())
print(dict(c.count_ops()), c.depth())

What is printed?

  • A. {} 0 — the circuits cancel to the identity
  • B. {'h': 2, 'cx': 2} 2
  • C. {'h': 2, 'cx': 2} 4
  • D. {'h': 1, 'cx': 1} 2

Q3. A researcher needs the singlet Bell state |Ψ⁻⟩ = (|01⟩ − |10⟩)/√2 as the input to an entanglement test. Starting from |00⟩, which snippet prepares it?

  • A. qc.h(0); qc.cx(0, 1)
  • B. qc.h(0); qc.cx(0, 1); qc.x(1)
  • C. qc.h(0); qc.cx(0, 1); qc.z(0)
  • D. qc.h(0); qc.cx(0, 1); qc.x(1); qc.z(1)

Q4. A student binds parameters by position and then samples the circuit with 1000 shots on an ideal simulator:

import numpy as np
from qiskit import QuantumCircuit
from qiskit.circuit import Parameter
 
phi, theta = Parameter('phi'), Parameter('theta')
qc = QuantumCircuit(1)
qc.rx(theta, 0)
qc.rz(phi, 0)
bound = qc.assign_parameters([np.pi, np.pi / 2])

Which measurement distribution (in the Z basis) results?

  • A. Approximately 50% '0' and 50% '1'
  • B. 100% '1'
  • C. 100% '0'
  • D. Approximately 85% '0' and 15% '1'

Q5. Which diagram is produced by qc.draw('text')?

qc = QuantumCircuit(3)
qc.h(0)
qc.cx(0, 2)
qc.x(1)
qc.cz(1, 2)
  • A.
     ┌───┐┌───┐
q_0: ┤ H ├┤ X ├───
     ├───┤└─┬─┘
q_1: ┤ X ├──┼───■─
     └───┘  │   │
q_2: ───────■───■─
  • B.
     ┌───┐
q_0: ┤ H ├──■─────
     ├───┤  │
q_1: ┤ X ├──┼───■─
     └───┘┌─┴─┐ │
q_2: ─────┤ X ├─■─
          └───┘
  • C.
     ┌───┐
q_0: ┤ H ├──■──────────
     └───┘┌─┴─┐┌───┐
q_1: ─────┤ X ├┤ X ├─■─
          └───┘└───┘ │
q_2: ────────────────■─
  • D.
     ┌───┐
q_0: ┤ H ├──■────■──
     └───┘  │    │
q_1: ───────┼────■──
          ┌─┴─┐┌───┐
q_2: ─────┤ X ├┤ X ├
          └───┘└───┘

Q6. After a mid-circuit measurement into classical register cr, a researcher wants to apply X if cr reads 1 and Z otherwise (classical feedforward). Which snippet is correct in Qiskit v2.x?

  • A. qc.x(0).c_if(cr, 1); qc.z(0).c_if(cr, 0)
  • B. if qc.measure(0, 0) == 1: qc.x(0)  else: qc.z(0)
  • C.
with qc.if_test((cr, 1)) as else_:
    qc.x(0)
with else_:
    qc.z(0)
  • D.
qc.if_test((cr, 1), qc.x(0), qc.z(0))

Q7. A 2-qubit Bell fragment is stitched into a larger register:

base = QuantumCircuit(3)
sub = QuantumCircuit(2)
sub.h(0); sub.cx(0, 1)
out = base.compose(sub, qubits=[2, 0])

Which statement describes out?

  • A. H acts on qubit 2; the CNOT has control qubit 2 and target qubit 0
  • B. H acts on qubit 0; the CNOT has control qubit 0 and target qubit 2
  • C. H acts on qubit 2; the CNOT has control qubit 0 and target qubit 2
  • D. compose raises an error because sub has fewer qubits than base

Q8. A lab implements standard teleportation of qubit 0's state to qubit 2. After the Bell measurement of qubits 0 and 1 into classical bits c0 and c1, which correction must be applied to qubit 2?

  • A. X conditioned on c0, then Z conditioned on c1 — but only if both bits are 1
  • B. H conditioned on c0 and S conditioned on c1
  • C. Z conditioned on both bits jointly equal to 0b11
  • D. X on qubit 2 conditioned on the measurement of qubit 1, and Z on qubit 2 conditioned on the measurement of qubit 0

Q9. A single Hadamard is translated for a heavy-hex device:

qc = QuantumCircuit(1)
qc.h(0)
pm = generate_preset_pass_manager(optimization_level=1,
                                  basis_gates=['rz', 'sx', 'x', 'cx'])
print(dict(pm.run(qc).count_ops()))

What is printed?

  • A. {'u': 1}
  • B. {'rz': 2, 'sx': 1}
  • C. {'rz': 1, 'sx': 2}
  • D. {'x': 1, 'sx': 1}

Q10. Which statement about generate_preset_pass_manager optimization levels in Qiskit v2.x is TRUE?

  • A. Level 0 skips layout and routing entirely, so the output may not match the coupling map
  • B. Level 3 is the default when optimization_level is omitted
  • C. Higher levels apply progressively more aggressive circuit optimization and typically take longer to compile
  • D. Level 1 automatically enables zero-noise extrapolation

Q11. What does qc.width() return here?

from qiskit import QuantumCircuit, QuantumRegister, ClassicalRegister
from qiskit.circuit import AncillaRegister
qr = QuantumRegister(3, 'q')
anc = AncillaRegister(2, 'a')
cr = ClassicalRegister(3, 'c')
qc = QuantumCircuit(qr, anc, cr)
  • A. 3
  • B. 5
  • C. 6
  • D. 8

Q12. A researcher squares a phase gate:

from qiskit.quantum_info import Operator
qs = QuantumCircuit(1); qs.s(0)
zc = QuantumCircuit(1); zc.z(0)
print(Operator(qs.power(2)).equiv(Operator(zc)))

What is printed?

  • A. True
  • B. False, because power only accepts parameterized circuits
  • C. False, because S² = T
  • D. True only if qs.power(2) is transpiled first

Section 2 — Perform Quantum Operations (Q13–Q23)

Q13. A researcher constructs Pauli('XZ') for a 2-qubit experiment. Which single-qubit operator acts on qubit 0?

  • A. X, because the string is read left to right starting at qubit 0
  • B. Z, because Pauli strings are little-endian: the rightmost character acts on qubit 0
  • C. Both act on qubit 0; Pauli('XZ') is the product XZ on one qubit
  • D. Neither — 'XZ' is an invalid Pauli label

Q14. What does this print?

from qiskit.quantum_info import SparsePauliOp
op = SparsePauliOp.from_list([("XZ", 1.0), ("XZ", 1.0),
                              ("II", 2.0), ("YY", 0.0)])
print(op.simplify())
  • A. SparsePauliOp(['XZ', 'XZ', 'II', 'YY'], coeffs=[1, 1, 2, 0])
  • B. SparsePauliOp(['XZ', 'II', 'YY'], coeffs=[2, 2, 0])
  • C. SparsePauliOp(['XZ', 'II'], coeffs=[2.+0.j, 2.+0.j])
  • D. SparsePauliOp(['II'], coeffs=[4.+0.j])

Q15. What is Statevector.from_label('01').data?

  • A. [0, 0, 1, 0] — the amplitude sits at index 2
  • B. [0, 1, 0, 0] — the amplitude sits at index 1
  • C. [1, 0, 0, 0]
  • D. [0, 0, 0, 1]

Q16. A state is evolved through a small circuit:

sv = Statevector.from_label('00')
qc = QuantumCircuit(2)
qc.h(0); qc.cx(0, 1); qc.x(1)
print(sv.evolve(qc).probabilities_dict())

What is printed (up to float rounding)?

  • A. {'00': 0.5, '11': 0.5}
  • B. {'00': 1.0}
  • C. {'11': 1.0}
  • D. {'01': 0.5, '10': 0.5}

Q17. During a debugging session, a colleague wraps a Z gate between two Hadamards on the same qubit: qc.h(0); qc.z(0); qc.h(0). This sequence is equivalent to which single gate?

  • A. X
  • B. Z
  • C. Y
  • D. S

Q18. For the Bell state prepared by h(0); cx(0, 1), what does the following print?

sv = Statevector.from_instruction(bell)
print(sv.expectation_value(Pauli('ZZ')),
      sv.expectation_value(Pauli('XX')),
      sv.expectation_value(Pauli('ZI')))
  • A. 1.0 0.0 1.0
  • B. 0.0 0.0 0.0
  • C. 1.0 1.0 0.0
  • D. 1.0 -1.0 0.5

Q19. A researcher checks whether an RZ rotation reproduces a Z gate:

qrz = QuantumCircuit(1); qrz.rz(np.pi, 0)
zc = QuantumCircuit(1); zc.z(0)
print(Operator(qrz).equiv(Operator(zc)), Operator(qrz) == Operator(zc))

What is printed?

  • A. True True
  • B. True False
  • C. False False
  • D. False True

Q20. For a 4-qubit device study, an observable applying Z only to qubit 2 (identity elsewhere) is needed. Which construction is correct?

  • A. SparsePauliOp.from_sparse_list([("Z", [2], 1.0)], num_qubits=4)
  • B. SparsePauliOp.from_list([("ZIII", 1.0)])
  • C. SparsePauliOp.from_list([("IIZI", 1.0)], num_qubits=4)from_list requires num_qubits
  • D. Pauli("Z", qubit=2)

Q21. What does this print?

from qiskit.quantum_info import Pauli
print(Pauli('X').tensor(Pauli('Z')), Pauli('X').expand(Pauli('Z')))
  • A. ZX XZ
  • B. XZ XZ
  • C. ZX ZX
  • D. XZ ZX

Q22. What does state_fidelity(Statevector.from_label('+'), Statevector.from_label('0')) return?

  • A. 0.7071
  • B. 0.5
  • C. 0.25
  • D. 1.0

Q23. (Choose two.) Which of the following operator pairs commute?

  • A. Pauli('X') and Pauli('Z')
  • B. Pauli('XX') and Pauli('ZZ')
  • C. Pauli('Z') and an rz(0.7) rotation on the same qubit
  • D. Pauli('X') and Pauli('Y')

Section 3 — Run Quantum Circuits (Q24–Q33)

Q24. A researcher wants the real device with the shortest queue that is currently online. Which call is correct?

  • A. service.least_busy(operational=True, simulator=False)
  • B. service.backends(least_busy=True, real=True)
  • C. service.get_backend("least_busy")
  • D. service.least_busy(queue="shortest")

Q25. A circuit containing an h gate (not in the backend's basis) and no layout is submitted directly to SamplerV2(mode=backend) for an IBM hardware backend. What happens?

  • A. The server transpiles it automatically before execution
  • B. It runs, but a warning about reduced fidelity is logged
  • C. The job is rejected with an error because the circuit is not an ISA circuit
  • D. The unsupported gates are silently skipped

Q26. A variational-algorithm loop needs dozens of sequential Estimator calls where each iteration depends on the previous result, without re-queuing between iterations. Which pattern is the intended one?

  • A. estimator = EstimatorV2(mode=Batch(backend=backend))
  • B.
with Session(backend=backend) as session:
    estimator = EstimatorV2(mode=session)
    # iterate: run, read result, update parameters
  • C. estimator = EstimatorV2(mode=backend) called in a Python for loop
  • D. session = backend.open_session(); estimator.run(session)

Q27. A group has 500 fully independent circuits (no feedback between jobs) and wants them scheduled efficiently as a single workload. Which execution mode fits best?

  • A. Session mode, because it reserves the device
  • B. Job mode, one submission per circuit
  • C. Local StatevectorSampler, since 500 circuits never run on hardware
  • D. Batch mode, which groups independent jobs for parallel scheduling

Q28. Which snippet runs a single ISA circuit in job mode on a specific backend object?

  • A. sampler = SamplerV2(mode=backend); job = sampler.run([isa_circuit])
  • B. job = backend.run(isa_circuit, primitive="sampler")
  • C. sampler = SamplerV2(backend.name); job = sampler.run(isa_circuit)
  • D. job = execute(isa_circuit, backend, shots=1024)

Q29. A GHZ circuit h(0); cx(0,1); cx(0,2); measure_all() is run with StatevectorSampler for 1000 shots. Which counts dictionary is plausible?

  • A. {'000': 250, '001': 250, '110': 250, '111': 250}
  • B. {'000': 1000}
  • C. {'111': 497, '000': 503}
  • D. {'100': 340, '010': 330, '001': 330}

Q30. What is printed?

qc = QuantumCircuit(1, 1); qc.h(0); qc.measure(0, 0)
result = StatevectorSampler(seed=1).run(
    [(qc, None, 2048), (qc,)], shots=1024).result()
print(result[0].data.c.num_shots, result[1].data.c.num_shots)
  • A. 1024 1024 — the run-level shots always wins
  • B. 2048 1024 — a PUB-level shot count overrides the run-level value
  • C. 2048 2048 — the first PUB sets shots for the whole job
  • D. A ValueError, because shots may only be set in one place

Q31. Why would a developer use FakeManilaV2 from qiskit_ibm_runtime.fake_provider during development?

  • A. It forwards jobs to the real Manila device at reduced cost
  • B. It is a 127-qubit noiseless statevector simulator
  • C. It validates OpenQASM syntax without executing anything
  • D. It runs locally with a noise model and coupling map snapshotted from the real device, so ISA transpilation and primitive workflows can be tested without queueing

Q32. Review this workflow destined for real hardware:

qc = QuantumCircuit(2)
qc.h(0); qc.cx(0, 1)
qc.measure_all()
pm = generate_preset_pass_manager(optimization_level=2, backend=backend)
isa = pm.run(qc)
sampler = SamplerV2(mode=backend)
job = sampler.run([qc])

What is the outcome?

  • A. It works: pm.run modifies qc in place
  • B. It works, but with more noise than necessary
  • C. The job fails: the untranspiled qc was submitted instead of isa, so the circuit does not match the backend ISA
  • D. pm.run raises an error because the circuit contains measurements

Q33. Which snippet correctly saves IBM Quantum Platform credentials for later QiskitRuntimeService() calls?

  • A. QiskitRuntimeService.save_account(channel="ibm_quantum_platform", token=MY_TOKEN, set_as_default=True)
  • B. QiskitRuntimeService.save_account(channel="ibm_quantum", token=MY_TOKEN)
  • C. QiskitRuntimeService(api_key=MY_TOKEN).save()
  • D. IBMQ.save_account(MY_TOKEN)

Section 4 — Use the Sampler Primitive (Q34–Q41)

Q34. A researcher runs the following and hits a problem:

qc = QuantumCircuit(2, 2)
qc.x(0)
qc.measure([0, 1], [0, 1])
result = sampler.run([qc]).result()
print(result[0].data.meas.get_counts())

What happens?

  • A. {'01': 1024} is printed
  • B. An AttributeError: the classical register is named c, so the data field is result[0].data.c; .meas exists only when measure_all() created the register
  • C. {'10': 1024} is printed
  • D. An error: SamplerV2 requires measure_all() rather than explicit measure

Q35. A 2-qubit circuit applies x(1) then measure_all() and is sampled for 100 shots on an ideal simulator. What is get_counts()?

  • A. {'01': 100}
  • B. {'11': 100}
  • C. {'10': 100}
  • D. {'1': 100}

Q36. A student passes a circuit with no measurement instructions to StatevectorSampler. What is the behavior?

  • A. The sampler measures all qubits implicitly, like measure_all()
  • B. A hard error is always raised before the job starts
  • C. It returns the exact statevector instead of samples
  • D. A warning is emitted and the PUB result's DataBin is empty — there is no classical output to sample

Q37. What is get_counts() after this parameterized run (200 shots, ideal)?

th = Parameter('th')
qc = QuantumCircuit(1, 1)
qc.ry(th, 0)
qc.measure(0, 0)
job = sampler.run([(qc, [np.pi])], shots=200)
  • A. {'1': 200}
  • B. {'0': 200}
  • C. {'0': 100, '1': 100}
  • D. An error: parameter values must be a dict

Q38. A device suffers decoherence on idle qubits during long circuits. Which snippet enables the appropriate suppression technique on a Sampler?

  • A. sampler.options.resilience_level = 2
  • B.
sampler.options.dynamical_decoupling.enable = True
sampler.options.dynamical_decoupling.sequence_type = "XpXm"
  • C. sampler.options.zne_mitigation = True
  • D. sampler.options.default_shots = 100_000

Q39. A teammate copies Estimator configuration onto a Sampler: sampler.options.resilience_level = 1. What is the correct assessment?

  • A. Valid — level 1 enables TREX on the Sampler
  • B. Valid but ignored silently
  • C. Invalid — resilience_level is an Estimator option; SamplerV2 supports twirling, dynamical decoupling, and shot options instead
  • D. Invalid — Sampler options are read-only after instantiation

Q40. A circuit measures qubit 0 (after an X gate) into 1-bit register first and qubit 1 into 1-bit register second. With 50 ideal shots:

print(result[0].join_data().get_counts())

What is printed?

  • A. {'10': 50}
  • B. {'1 0': 50}
  • C. {'11': 50}
  • D. {'01': 50} — registers are concatenated with later-added registers as the more significant bits

Q41. A 2-qubit measure_all() circuit is sampled with shots=100. For ba = result[0].data.meas, what is (ba.num_shots, ba.num_bits, len(ba.get_bitstrings()))?

  • A. (100, 2, 100)
  • B. (100, 2, 4)
  • C. (2, 100, 100)
  • D. (100, 4, 100)

Section 5 — Use the Estimator Primitive (Q42–Q49)

Q42. For the Bell state circuit (no measurements), what does this print?

est = StatevectorEstimator()
obs = [SparsePauliOp('ZZ'), SparsePauliOp('XX'), SparsePauliOp('ZI')]
result = est.run([(bell, obs)]).result()
print(result[0].data.evs)
  • A. [0. 0. 0.]
  • B. [1. 1. 0.]
  • C. [1. 0. 1.]
  • D. [0.5 0.5 0.5]

Q43. A researcher reuses a Sampler circuit (ending in measure_all()) in an Estimator PUB with observable ZZ. What happens?

  • A. The measurements are ignored and ⟨ZZ⟩ is returned
  • B. The estimator converts the measurements into the observable basis
  • C. An error is raised — Estimator circuits must not contain measurements; the observable defines the measurement basis
  • D. evs is returned, but doubled because measurement and observable overlap

Q44. Which snippet is the correct end-to-end hardware Estimator workflow for a Bell circuit and observable ZZ?

  • A.
pm = generate_preset_pass_manager(optimization_level=1, backend=backend)
isa = pm.run(bell)
mapped = SparsePauliOp('ZZ').apply_layout(isa.layout)
estimator = EstimatorV2(mode=backend)
ev = estimator.run([(isa, mapped)]).result()[0].data.evs
  • B.
isa = pm.run(bell)
estimator = EstimatorV2(mode=backend)
ev = estimator.run([(isa, SparsePauliOp('ZZ'))]).result()[0].data.evs
  • C.
mapped = SparsePauliOp('ZZ').apply_layout(bell.layout)
isa = pm.run(bell)
ev = estimator.run([(isa, mapped)]).result()[0].data.evs
  • D.
isa = pm.run(bell)
mapped = isa.apply_layout(SparsePauliOp('ZZ'))
ev = estimator.run([(isa, mapped)]).result()[0].data.evs

Q45. A parameter sweep uses broadcasting:

t = Parameter('t')
qc = QuantumCircuit(1); qc.rx(t, 0)
obs = [[SparsePauliOp('Z')], [SparsePauliOp('X')]]     # shape (2, 1)
params = [[0.0], [np.pi / 2], [np.pi]]                 # 3 parameter sets
result = StatevectorEstimator().run([(qc, obs, params)]).result()
print(result[0].data.evs.shape)
print(np.round(result[0].data.evs, 3))

What is printed?

  • A. (3,) then [1. 0. -1.]
  • B. (6,) then [1. 0. -1. 0. 0. 0.]
  • C. An error — observables and parameter sets must have identical shapes
  • D. (2, 3) then [[ 1. 0. -1.] [ 0. 0. 0.]]

Q46. Which statement about Runtime Estimator resilience levels is TRUE?

  • A. Level 0 applies measurement-error mitigation only
  • B. Level 1 (the default) applies measurement-error mitigation (TREX); level 2 adds zero-noise extrapolation
  • C. Level 2 applies probabilistic error cancellation by default
  • D. Level 1 disables all twirling

Q47. A researcher wants explicit ZNE with noise factors 1, 3, 5 and an exponential extrapolator. Which configuration is correct?

  • A. estimator.options.zne = {"factors": [1, 3, 5], "fit": "exp"}
  • B. estimator.options.resilience_level = 3
  • C.
estimator.options.resilience.zne_mitigation = True
estimator.options.resilience.zne.noise_factors = (1, 3, 5)
estimator.options.resilience.zne.extrapolator = "exponential"
  • D. estimator.options.dynamical_decoupling.enable = True with sequence_type="ZNE"

Q48. For qc.rx(np.pi/3, 0) on one qubit, what does the Estimator return for observable Z (ideal)?

  • A. 0.5
  • B. 0.866
  • C. -0.5
  • D. 1.0

Q49. (Choose two.) A paper's methods section must separate error suppression from error mitigation. Which two techniques are suppression (acting before/during execution rather than in post-processing)?

  • A. Dynamical decoupling
  • B. Zero-noise extrapolation
  • C. Pauli twirling
  • D. Probabilistic error cancellation

Section 6 — Visualize Circuits, Measurements, and States (Q50–Q57)

Q50. Which code produces this draw('text') output?

     ┌───┐┌───┐     ┌─┐
q_0: ┤ H ├┤ Z ├──■──┤M├───
     └───┘└───┘┌─┴─┐└╥┘┌─┐
q_1: ──────────┤ X ├─╫─┤M├
               └───┘ ║ └╥┘
c: 2/════════════════╩══╩═
                     0  1
  • A. qc.z(0); qc.h(0); qc.cx(0, 1); qc.measure([0, 1], [0, 1])
  • B. qc.h(0); qc.z(0); qc.cx(0, 1); qc.measure([0, 1], [0, 1])
  • C. qc.h(0); qc.z(1); qc.cx(0, 1); qc.measure([0, 1], [0, 1])
  • D. qc.h(0); qc.z(0); qc.cx(1, 0); qc.measure([0, 1], [0, 1])

Q51. A textbook draws its circuits with the most significant qubit on top, but draw() puts q_0 on top by default. Which call matches the textbook layout?

  • A. qc.draw('mpl', flip=True)
  • B. qc.draw('text', idle_wires=False)
  • C. qc.draw('mpl', reverse_bits=True)
  • D. qc.reverse_bits_draw()

Q52. plot_bloch_multivector is called on the Bell state (|00⟩ + |11⟩)/√2. What does the figure show?

  • A. Both per-qubit Bloch vectors have zero length (points at the sphere's center) because each reduced state is maximally mixed
  • B. Both vectors point along +X
  • C. Qubit 0 along +Z, qubit 1 along −Z
  • D. One combined sphere with two arrows at ±Z

Q53. On a plot_state_qsphere figure, how are amplitude and phase encoded?

  • A. Amplitude = color, phase = distance from the pole
  • B. Amplitude = arrow direction, phase = arrow length
  • C. Both are encoded as latitude on the sphere
  • D. The blob size reflects the probability of the basis state; the color encodes its relative phase

Q54. A 3-qubit circuit applies only x(2) then measure_all(); the counts are passed to plot_histogram. What does the plot show?

  • A. A single bar at '001'
  • B. A single bar at '100'
  • C. Two bars at '000' and '100'
  • D. Eight equal bars

Q55. A researcher wants ideal-simulator counts and hardware counts on one histogram, labeled. Which call is correct?

  • A. plot_histogram([ideal_counts, hw_counts], legend=["ideal", "hardware"])
  • B. plot_histogram(ideal_counts + hw_counts, labels=["ideal", "hardware"])
  • C. plot_histogram({"ideal": ideal_counts, "hardware": hw_counts})
  • D. plot_histogram(ideal_counts, overlay=hw_counts)

Q56. The state (|0⟩ − i|1⟩)/√2 sits where on the Bloch sphere?

  • A. +Y axis
  • B. −X axis
  • C. −Y axis
  • D. +Z axis

Q57. A single qubit undergoes h(0) then s(0), and plot_bloch_multivector is called on the resulting statevector. Where does the vector point?

  • A. +X axis — S leaves |+⟩ unchanged
  • B. −Z axis
  • C. −Y axis
  • D. +Y axis — the state is (|0⟩ + i|1⟩)/√2

Section 7 — Retrieve and Analyze Results (Q58–Q64)

Q58. A job was submitted yesterday from a laptop that has since been rebooted; only the job ID string was saved. How is the result retrieved?

  • A. job = SamplerV2.retrieve(job_id); job.result()
  • B. service = QiskitRuntimeService(); job = service.job(job_id); result = job.result()
  • C. result = backend.results(job_id)
  • D. Results are lost when the Python session ends

Q59. Hardware counts for a 1-qubit circuit are {'0': 600, '1': 400} (1000 shots). What is the estimate of ⟨Z⟩ computed from these counts?

  • A. 0.2
  • B. 0.6
  • C. -0.2
  • D. 0.4

Q60. An Estimator result's standard error is twice as large as the target. Approximately how must the shot count change to halve the standard error?

  • A. Double the shots
  • B. Halve the shots
  • C. Quadruple the shots — standard error scales as 1/√shots
  • D. Increase shots by √2

Q61. Three Sampler PUBs are submitted in one run call. What does len(job.result()) return, and how is the second PUB's data accessed?

  • A. 1; all PUBs merge into result[0]
  • B. 3; via result[1].data
  • C. 3; via result.pubs[2]
  • D. 2; the identical PUBs are deduplicated

Q62. After a hardware run, a researcher must report consumed QPU time for a grant. Which call gives it?

  • A. job.status().qpu_time
  • B. job.result().metadata["wall_clock"]
  • C. len(job.result()) * shots
  • D. job.usage() (with job.metrics() for detailed timestamps)

Q63. Counts for a 2-qubit circuit are {'00': 400, '01': 100, '10': 100, '11': 400} over 1000 shots. What is the manual estimate of ⟨ZZ⟩?

  • A. 0.8
  • B. 0.0
  • C. 0.6 — even-parity strings count +1, odd-parity strings count −1
  • D. -0.6

Q64. An ideal simulator gives a GHZ circuit only '000' and '111', but the hardware histogram also shows small bars at '001', '010', '110', etc. What is the best explanation?

  • A. Gate errors and readout errors on the device populate outcomes that are impossible ideally
  • B. The hardware uses big-endian ordering, so the extra strings are relabeled ideal outcomes
  • C. measure_all() measured the ancilla qubits too
  • D. The transpiler added SWAPs, which change the sampled distribution

Section 8 — Operate with OpenQASM (Q65–Q68)

Q65. What does qiskit.qasm3.dumps(qc) output for a Bell circuit built as QuantumCircuit(2, 2) with h(0), cx(0, 1), and measure([0, 1], [0, 1])?

  • A.
OPENQASM 2.0;
include "qelib1.inc";
qreg q[2];
creg c[2];
h q[0];
cx q[0],q[1];
measure q -> c;
  • B.
OPENQASM 3.0;
include "stdgates.inc";
bit[2] c;
qubit[2] q;
h q[0];
cx q[0], q[1];
c[0] = measure q[0];
c[1] = measure q[1];
  • C.
OPENQASM 3.0;
qubit q[2];
bit c[2];
H q[0];
CX q[0], q[1];
measure q -> c;
  • D.
OPENQASM 3.0;
include "stdgates.inc";
qreg q[2];
creg c[2];
h q[0];
cx q[0], q[1];
c = measure q;

Q66. This OpenQASM 2 program is loaded with qiskit.qasm2.loads and run on an ideal simulator with many shots:

OPENQASM 2.0;
include "qelib1.inc";
qreg q[2];
creg c[2];
x q[0];
h q[1];
cx q[1],q[0];
measure q -> c;

Which distribution results?

  • A. {'11': ~50%, '00': ~50%}
  • B. {'01': 100%}
  • C. {'01': ~50%, '10': ~50%}
  • D. {'11': 100%}

Q67. Which capability exists in OpenQASM 3 but NOT in OpenQASM 2?

  • A. The include statement
  • B. Two-qubit gates such as cx
  • C. Classical registers
  • D. Typed classical data, input parameters, and classical control flow (e.g., if/while blocks)

Q68. A collaborator emails the file teleport.qasm containing an OpenQASM 3 program. Which snippet turns it into a QuantumCircuit?

  • A. from qiskit import qasm3; qc = qasm3.load("teleport.qasm")
  • B. qc = qasm3.loads("teleport.qasm")
  • C. qc = QuantumCircuit.from_qasm_file_v3("teleport.qasm")
  • D. qc = qasm3.dump("teleport.qasm")

End of Paper 10. Check your answers against paper-10-FULL-answers.md. Target: 47+ to pass; 58+ means you are exam-ready with margin.