Skip to content

Instantly share code, notes, and snippets.

View prince-ph0en1x's full-sized avatar
🤖
Quantum Intelligence

Aritra Sarkar prince-ph0en1x

🤖
Quantum Intelligence
View GitHub Profile
@limitedmage
limitedmage / qubit.py
Created April 27, 2011 23:34
Python Quantum Computing simulator
import math
import random
class Qubit:
def __init__(self, a = 1, b = 0):
'''Initialize a single qubit'''
self.zero = complex(a)
self.one = complex(b)
def xgate(self):