Q# Python Bindings
Project description
Q# Language Support for Python
Q# is an open-source, high-level programming language for developing and running quantum algorithms.
The qsharp
package for Python provides interoperability with the Q# interpreter, making it easy
to simulate Q# programs within Python.
Installation
To install the Q# language package, run:
pip install qsharp
Usage
First, import the qsharp
module:
import qsharp
Then, use the %%qsharp
cell magic to run Q# directly in Jupyter notebook cells:
%%qsharp
open Microsoft.Quantum.Diagnostics;
@EntryPoint()
operation BellState() : Unit {
use qs = Qubit[2];
H(qs[0]);
CNOT(qs[0], qs[1]);
DumpMachine();
ResetAll(qs);
}
BellState()
Support
For more information about the Azure Quantum Development Kit, visit https://aka.ms/AQ/Documentation.
Contributing
Q# welcomes your contributions! Visit the Q# GitHub repository at [https://github.com/microsoft/qsharp] to find out more about the project.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Hashes for qsharp-1.6.3.dev0-cp38-abi3-win_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | be50c0a0206add145b37949e3870a70476b0722ff3c40a240abcb7b585a3a0b5 |
|
MD5 | d34eae860cbadebb0067dda9ed343816 |
|
BLAKE2b-256 | 17b92f766f32f9b400847c61ad6180fb6a77fd3fcd0956d2d70ea8ad642d071a |
Hashes for qsharp-1.6.3.dev0-cp38-abi3-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 82ae0c2f00d4f6c5b70237107f27bbab683d8cdfb80a6c2150c1bca917586fd7 |
|
MD5 | 5b45fcbfd6fabfe870f7d624cb7bcc7e |
|
BLAKE2b-256 | 8ab1e2430b8d9ff1e263bcf2954cd6db5bd1538c7219a6bd41bd28e9e4a48d79 |
Hashes for qsharp-1.6.3.dev0-cp38-abi3-manylinux_2_31_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | acb27a4734bedb9da1021119c06f5e3de856ae4af2d265293e35bb92f092c9ca |
|
MD5 | 8e8bf62ebaade7971020dd173223f2b9 |
|
BLAKE2b-256 | a1fcea0fc909d115dc39d3b494600c610d1053593ece637ae6d60b5827b5326c |
Hashes for qsharp-1.6.3.dev0-cp38-abi3-manylinux_2_31_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | bfe14c41b177fd544e1105d9ccc73e69a009b68b95dad0c563ef5ceec5d01524 |
|
MD5 | 7946d3221cc04b5542eb3f01d5c70312 |
|
BLAKE2b-256 | f640cdb6bea7be11e618de9af09897d11f218c6ea84ef81eaab69d9583728ff9 |
Hashes for qsharp-1.6.3.dev0-cp38-abi3-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f2d625b0149c3148f84fa81cf6c8cd968ee7a6a3d0bbb759bea16c912700c223 |
|
MD5 | 07986ea45c3f31e6d5c5ab5770c796ac |
|
BLAKE2b-256 | 8d6a3533cb6005c674be4bd50f9309ebaec9ef463e24cf9779e1fdbce9d93011 |