|q⟩
Bad Qubits
Play
Quest
Questions
Learn
Playground
☕
← Question Bank
Multiple choice
A phase oracle implements
∣
x
⟩
→
(
−
1
)
f
(
x
)
∣
x
⟩
|x\rangle \to (-1)^{f(x)} |x\rangle
∣
x
⟩
→
(
−
1
)
f
(
x
)
∣
x
⟩
. For the single-bit identity function
f
(
x
)
=
x
f(x)=x
f
(
x
)
=
x
(so
f
(
0
)
=
0
f(0)=0
f
(
0
)
=
0
,
f
(
1
)
=
1
f(1)=1
f
(
1
)
=
1
), which single-qubit gate is the phase oracle?
The identity I, since a phase is never observable
H, since it creates a superposition
Z, since
Z
∣
0
⟩
=
∣
0
⟩
Z|0\rangle=|0\rangle
Z
∣0
⟩
=
∣0
⟩
and
Z
∣
1
⟩
=
−
∣
1
⟩
Z|1\rangle=-|1\rangle
Z
∣1
⟩
=
−
∣1
⟩
X, since it flips
∣
0
⟩
|0\rangle
∣0
⟩
and
∣
1
⟩
|1\rangle
∣1
⟩
Check answer