Set qubits based on the boolean values given.
| C# | Visual Basic | Visual C++ |
IQuantumRegister SetQubits( bool[] QubitValues )
Function SetQubits ( _ QubitValues As Boolean() _ ) As IQuantumRegister
IQuantumRegister^ SetQubits( array<bool>^ QubitValues )
- QubitValues (array< Boolean >[]()[])
- Values to set each qubit to. Qubit at position x will be set to the boolean element at position x in QubitValues.
A reference to the modified register.
| Exception | Condition |
|---|---|
| ArgumentNullException | Thrown if QubitValues is null. |
| ArgumentOutOfRangeException | Thrown if the length of QubitValues
does not match the length of the exposed qubits in the register. |