import qiskit.quantum_info as qi #this is used to do calculations
from qiskit.circuit.library import FourierChecking
from qiskit.visualization import plot_histogram

f=[1,-1,-1,-1]
g=[1,1,-1,-1]

circuit = FourierChecking(f=f,g=g)
circuit.draw()

zero = qi.Statevector.from_label('00')
sv = zero.evolve(circuit)
probs = sv.probabilities_dict()
plot_histogram(probs)

print(probs)



