code: 
  
  
  
  
  
  
  """simple docstring"""
  def        A	(							__snake_case:   int = 1_0_0_0     )						->		int:
  
         """simple docstring"""
  
  
  
  
  
         return sum(i for i in range(__snake_case     ) if i % 3 == 0 or i % 5 == 0     )
  
  
  if __name__ == "__main__":
   print(f"""{solution() = }""")
style_context: 
  
  
  
  
  
  
  """simple docstring"""
  import numpy as np
  import qiskit
  
  
  def        A	(							__snake_case:   str   ,    __snake_case:   int     )						->		qiskit.QuantumCircuit:
  
         """simple docstring"""
  
  
  
  
  
         __magic_name__										=						qiskit.QuantumCircuit(num_qubits + 1     )
  
         # First, let's deal with the case in which oracle is balanced
         if case == "balanced":
                # First generate a random number that tells us which CNOTs to
                # wrap in X-gates:
                __magic_name__										=						np.random.randint(1   ,    2**num_qubits     )
                # Next, format 'b' as a binary string of length 'n', padded with zeros:
                __magic_name__										=						format(__snake_case   ,    F"""0{num_qubits}b"""     )
                # Next, we place the first X-gates. Each digit in our binary string
                # corresponds to a qubit, if the digit is 0, we do nothing, if it's 1
                # we apply an X-gate to that qubit:
                for index, bit in enumerate(__snake_case     ):
                       if bit == "1":
                              oracle_qc.x(__snake_case     )
          # Do the controlled-NOT gates for each qubit, using the output qubit
          # as the target:
                for index in range(__snake_case     ):
                       oracle_qc.cx(__snake_case   ,    __snake_case     )
                # Next, place the final X-gates
                for index, bit in enumerate(__snake_case     ):
                       if bit == "1":
                              oracle_qc.x(__snake_case     )
  
      # Case in which oracle is constant
         if case == "constant":
                # First decide what the fixed output of the oracle will be
                # (either always 0 or always 1)
                __magic_name__										=						np.random.randint(2     )
                if output == 1:
                       oracle_qc.x(__snake_case     )
  
         __magic_name__										=						oracle_qc.to_gate()
         __magic_name__										=						'Oracle'  # To show when we display the circuit
         return oracle_gate
  
  
  def        A	(							__snake_case:   qiskit.QuantumCircuit   ,    __snake_case:   int     )						->		qiskit.QuantumCircuit:
  
         """simple docstring"""
  
  
  
  
  
         __magic_name__										=						qiskit.QuantumCircuit(num_qubits + 1   ,    __snake_case     )
         # Set up the output qubit:
         dj_circuit.x(__snake_case     )
         dj_circuit.h(__snake_case     )
         # And set up the input register:
         for qubit in range(__snake_case     ):
                dj_circuit.h(__snake_case     )
         # Let's append the oracle gate to our circuit:
         dj_circuit.append(__snake_case   ,    range(num_qubits + 1     )     )
         # Finally, perform the H-gates again and measure:
         for qubit in range(__snake_case     ):
                dj_circuit.h(__snake_case     )
  
         for i in range(__snake_case     ):
                dj_circuit.measure(__snake_case   ,    __snake_case     )
  
         return dj_circuit
  
  
  def        A	(							__snake_case:   str   ,    __snake_case:   int     )						->		qiskit.result.counts.Counts:
  
         """simple docstring"""
  
  
  
  
  
         __magic_name__										=						qiskit.Aer.get_backend('aer_simulator'     )
  
         __magic_name__										=						dj_oracle(__snake_case   ,    __snake_case     )
         __magic_name__										=						dj_algorithm(__snake_case   ,    __snake_case     )
  
         # Execute the circuit on the simulator
         __magic_name__										=						qiskit.execute(__snake_case   ,    __snake_case   ,    shots=1_0_0_0     )
  
         # Return the histogram data of the results of the experiment.
         return job.result().get_counts(__snake_case     )
  
  
  if __name__ == "__main__":
   print(f"""Deutsch Jozsa - Constant Oracle: {deutsch_jozsa('constant', 3)}""")
   print(f"""Deutsch Jozsa - Balanced Oracle: {deutsch_jozsa('balanced', 3)}""")