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
import Std.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.8.4.dev0-cp38-abi3-win_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b8fd99eddbc42fbfac48f08ad007119925e288852eaa3d726c11a666e91d6eb5 |
|
MD5 | 65e320016828d3b04235bdbb79d05b91 |
|
BLAKE2b-256 | c4421d382c5b6b0f6c8003ffe3878ecfb8cafd19c9c35fcf4a2ee6da44c5216c |
Hashes for qsharp-1.8.4.dev0-cp38-abi3-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6fb90234333fbf4426ce955bd03e949066783f1ba28e3047b5fe3ae6dce02d62 |
|
MD5 | 09f6fbbd652e1a6c2481a3edf18e023e |
|
BLAKE2b-256 | 2c7e7d606d512c4c66d75f08fbf667dd8627096d421aadb8ee260465e73d377d |
Hashes for qsharp-1.8.4.dev0-cp38-abi3-manylinux_2_31_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b766a9948cd5234a60c35b82e40a73cf766074280e70ff8c86258abea95b45b7 |
|
MD5 | fbf0cd17fb052e993643bfb736e5b6e2 |
|
BLAKE2b-256 | eea89131130d61772485ecfed733cea4921e51fbe1baefa4fa8b4d04e336db7d |
Hashes for qsharp-1.8.4.dev0-cp38-abi3-manylinux_2_31_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ab9513e8eb9baf89a90de1469244c68389ebdf5d8e6767366bdc1c3ddc02019a |
|
MD5 | f0972593be26457e8a849741398e08e9 |
|
BLAKE2b-256 | df8186ec4f64c12e696b6aa7ed1669cd689d8e9fbf7dfbdfb37c815b7dd9b718 |
Hashes for qsharp-1.8.4.dev0-cp38-abi3-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a55a71fb686db116fe2a010e2de759134e6a371d58bd63689f0afa6dd7d47ead |
|
MD5 | b128260680539dbd260925097a189418 |
|
BLAKE2b-256 | 362c8351ec02070c8e3dbf2c3a5935ed49047cd090db7826193b0581bd75fe1c |