Returns a slice (subset) of the register from the beginning to EndIndex, then
has the operations applied to it.
| C# | Visual Basic | Visual C++ |
IQuantumRegister SliceTo( int EndIndex, List<IQuantumOperation> Operations )
Function SliceTo ( _ EndIndex As Integer, _ Operations As List(Of IQuantumOperation) _ ) As IQuantumRegister
IQuantumRegister^ SliceTo( int EndIndex, List<IQuantumOperation^>^ Operations )
- EndIndex (Int32)
- The ending index of the slice.
- Operations (List<(Of <(IQuantumOperation>)>))
- The operations to apply to the slice.
The quantum register representing the slice.
| Exception | Condition |
|---|---|
| NotUnitaryOperationException | Thrown if a non-unitary operation is
passed. All quantum operations must be unitary. |
| SizeMismatchException | Thrown if the size of one of the operations
does not match the size of the register. |