Skip to content

Instantly share code, notes, and snippets.

Avatar

Bill CX billchenxi

View GitHub Profile
View nginx.pod.yml
apiVersion: v1
kind: Pod
metadata:
name: test
labels:
app: nginx
rel: stable
spec:
containers:
- name: test
View Teleportation_1.qs
operation Teleportation(sentMessage : Bool) : Bool {
mutable receivedMessage = false;
using (register = Qubit[3]) {
let message = register[0];
if (sentMessage) {
X(message); // flip the message to "true"
}
View Teleportation.qs
namespace Q_Teleportation {
open Microsoft.Quantum.Canon;
open Microsoft.Quantum.Intrinsic;
operation Teleportation(sentMessage : Bool) : Bool {
mutable receivedMessage = false;
using (register = Qubit[3]) {
let message = register[0];
View Teleportation.qs
namespace Q_Teleportation {
open Microsoft.Quantum.Canon;
open Microsoft.Quantum.Intrinsic;
operation Teleportation(sentMessage : Bool) : Bool {
mutable receivedMessage = false;
using (register = Qubit[3]) {
let message = register[0];
View Entanglement.qs
namespace Q_Entanglement {
open Microsoft.Quantum.Canon;
open Microsoft.Quantum.Intrinsic;
operation Entanglement() : (Result, Result) {
mutable Q1_state = Zero;
mutable Q2_state = Zero;
using ((Q1, Q2) = (Qubit(), Qubit())) {
H(Q1);
View full_superposition.gs
namespace Q_superposition {
open Microsoft.Quantum.Canon;
open Microsoft.Quantum.Intrinsic;
operation Superposition() : Result {
mutable state = Zero;
using (qubit = Qubit()) {
H(qubit);
set state = M(qubit);
View Superposition.qs
namespace Q_superposition {
open Microsoft.Quantum.Canon;
open Microsoft.Quantum.Intrinsic;
operation Superposition() : Result {
mutable state = Zero;
using (qubit = Qubit()) {
H(qubit);
set state = M(qubit);
View gist:e044aa78a508a1a590f28c66e424b03f
namespace testing123 {
open Microsoft.Quantum.Canon;
open Microsoft.Quantum.Intrinsic;
@EntryPoint()
operation HelloQ() : Unit {
Message("Hello quantum world!");
}
View gist:445cfa6f95c3d7288fa61bb8cedd4780
version: '3'
services:
db:
image: mysql
container_name: mysql_db
restart: always
environment:
- MYSQL_ROOT_PASSWORD="secret"
web:
image: apache
You can’t perform that action at this time.