<s>
Q#	O
(	O
pronounced	O
as	O
Q	B-Device
sharp	I-Device
)	O
is	O
a	O
domain-specific	B-Language
programming	I-Language
language	I-Language
used	O
for	O
expressing	O
quantum	B-Device
algorithms	I-Device
.	O
</s>
<s>
It	O
was	O
initially	O
released	O
to	O
the	O
public	O
by	O
Microsoft	O
as	O
part	O
of	O
the	O
Quantum	B-Device
Development	I-Device
Kit	I-Device
.	O
</s>
<s>
Historically	O
,	O
Microsoft	O
Research	O
had	O
two	O
teams	O
interested	O
in	O
quantum	B-Device
computing	O
,	O
the	O
QuArC	O
team	O
based	O
in	O
Redmond	O
,	O
directed	O
by	O
Krysta	O
Svore	O
,	O
that	O
explored	O
the	O
construction	O
of	O
quantum	B-Device
circuitry	O
,	O
and	O
Station	O
Q	O
initially	O
located	O
in	O
Santa	O
Barbara	O
and	O
directed	O
by	O
Michael	O
Freedman	O
,	O
that	O
explored	O
topological	B-Device
quantum	I-Device
computing	I-Device
.	O
</s>
<s>
During	O
a	O
Microsoft	O
Ignite	O
Keynote	O
on	O
September	O
26	O
,	O
2017	O
,	O
Microsoft	O
announced	O
that	O
they	O
were	O
going	O
to	O
release	O
a	O
new	O
programming	O
language	O
geared	O
specifically	O
towards	O
quantum	B-Device
computers	O
.	O
</s>
<s>
On	O
December	O
11	O
,	O
2017	O
,	O
Microsoft	O
released	O
Q#	O
as	O
a	O
part	O
of	O
the	O
Quantum	B-Device
Development	I-Device
Kit	I-Device
.	O
</s>
<s>
At	O
Build	O
2019	O
,	O
Microsoft	O
announced	O
that	O
it	O
would	O
be	O
open-sourcing	O
the	O
Quantum	B-Device
Development	I-Device
Kit	I-Device
,	O
including	O
its	O
Q#	O
compilers	O
and	O
simulators	O
.	O
</s>
<s>
Q#	O
is	O
available	O
as	O
a	O
separately	O
downloaded	O
extension	O
for	O
Visual	B-Application
Studio	I-Application
,	O
but	O
it	O
can	O
also	O
be	O
run	O
as	O
an	O
independent	O
tool	O
from	O
the	O
Command	O
line	O
or	O
Visual	B-Application
Studio	I-Application
Code	O
.	O
</s>
<s>
The	O
Quantum	B-Device
Development	I-Device
Kit	I-Device
ships	O
with	O
a	O
quantum	B-Device
simulator	I-Device
which	O
is	O
capable	O
of	O
running	O
Q#	O
.	O
</s>
<s>
In	O
order	O
to	O
invoke	O
the	O
quantum	B-Device
simulator	I-Device
,	O
another	O
.NET	B-Application
programming	I-Application
language	I-Application
,	O
usually	O
C#	B-Application
,	O
is	O
used	O
,	O
which	O
provides	O
the	O
(	O
classical	O
)	O
input	O
data	O
for	O
the	O
simulator	O
and	O
reads	O
the	O
(	O
classical	O
)	O
output	O
data	O
from	O
the	O
simulator	O
.	O
</s>
<s>
As	O
a	O
consequence	O
,	O
some	O
of	O
the	O
most	O
prominent	O
features	O
of	O
Q#	O
are	O
the	O
ability	O
to	O
entangle	O
and	O
introduce	O
superpositioning	O
to	O
qubits	O
via	O
Controlled	O
NOT	O
gates	O
and	O
Hadamard	O
gates	O
,	O
respectively	O
,	O
as	O
well	O
as	O
Toffoli	O
Gates	O
,	O
Pauli	O
X	O
,	O
Y	O
,	O
Z	O
Gate	O
,	O
and	O
many	O
more	O
which	O
are	O
used	O
for	O
a	O
variety	O
of	O
operations	O
;	O
see	O
the	O
list	O
at	O
the	O
article	O
on	O
quantum	B-Device
logic	O
gates	O
.	O
</s>
<s>
The	O
hardware	O
stack	O
that	O
will	O
eventually	O
come	O
together	O
with	O
Q#	O
is	O
expected	O
to	O
implement	O
Qubits	O
as	O
topological	B-Device
qubits	I-Device
.	O
</s>
<s>
The	O
quantum	B-Device
simulator	I-Device
that	O
is	O
shipped	O
with	O
the	O
Quantum	B-Device
Development	I-Device
Kit	I-Device
today	O
is	O
capable	O
of	O
processing	O
up	O
to	O
32	O
qubits	O
on	O
a	O
user	O
machine	O
and	O
up	O
to	O
40	O
qubits	O
on	O
Azure	B-Application
.	O
</s>
<s>
is	O
also	O
a	O
large	O
collection	O
of	O
sample	O
programs	O
implementing	O
a	O
variety	O
of	O
Quantum	B-Device
algorithms	I-Device
and	O
their	O
tests	O
.	O
</s>
<s>
Microsoft	O
has	O
also	O
hosted	O
a	O
Quantum	B-Device
Coding	I-Device
contest	O
on	O
Codeforces	O
,	O
called	O
,	O
and	O
also	O
provided	O
related	O
material	O
to	O
help	O
answer	O
the	O
questions	O
in	O
the	O
blog	O
posts	O
,	O
plus	O
the	O
detailed	O
solutions	O
in	O
the	O
tutorials	O
.	O
</s>
<s>
Q#	O
is	O
syntactically	O
related	O
to	O
both	O
C#	B-Application
and	O
F#	B-Operating_System
yet	O
also	O
has	O
some	O
significant	O
differences	O
.	O
</s>
<s>
The	O
following	O
source	O
code	O
is	O
a	O
multiplexer	B-Protocol
from	O
the	O
official	O
Microsoft	O
Q#	O
library	O
repository	O
.	O
</s>
