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.4.dev0-cp38-abi3-win_arm64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fe3e5a6de30e27a7fb6f41809a32fddcd1bff06f16ff6f971d1f3d3793071ea4 |
|
MD5 | d5f7ea75a38475769b668122acc02ad8 |
|
BLAKE2b-256 | d05743576d4456d7ecf3e98d1054a8a9e6a947b0113c3788931e536abb610a74 |
Hashes for qsharp-1.6.4.dev0-cp38-abi3-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5151f3eb74334fd7401ff891bb94418fd399208024b917c5ea479a3a16c8e7e5 |
|
MD5 | b83651583ae1d0965eed5f8496f2b733 |
|
BLAKE2b-256 | 16b2fe00a6e8155ce41e01e22dd1ad01064f08a3a328bef9cf221b335f04e3b1 |
Hashes for qsharp-1.6.4.dev0-cp38-abi3-manylinux_2_31_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d23943a6bcf9af9e9f31ae5459bf8b6d2c43c109b5eca412dbe38a89ce4954b1 |
|
MD5 | b04d5c0e4320b67b2bc1f5d009be94fd |
|
BLAKE2b-256 | dbb6d05403f701b1dad1435e624a4c4666e5f08cce0ad77eb24ca7e4ff67d5a1 |
Hashes for qsharp-1.6.4.dev0-cp38-abi3-manylinux_2_31_aarch64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2029935af57007dcf327b4a95bdaf5331b7062fe3488915952e1bde047b5a4c0 |
|
MD5 | 5ac69299bb9237bc3cd8adfffaf799e0 |
|
BLAKE2b-256 | 76d43e00ddd8a8619483ec834679a687d0aa0999bc76f76b7c4ac9f007b8335d |
Hashes for qsharp-1.6.4.dev0-cp38-abi3-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8a94f19b5a1a5566222e3134a15dbf7615fb8d9d1d4e4f12809885961042723d |
|
MD5 | 73cde1dd1150eb48254f1229879e39af |
|
BLAKE2b-256 | 23e4f4a6ef1574aeebea06b624442637c248aa27f6652ece3f091c72aaae31ba |