diff --git a/README.md b/README.md index a28740d..777ee75 100644 --- a/README.md +++ b/README.md @@ -388,6 +388,7 @@ Meet [FizzBuzz](https://github.com/zenware/FizzBuzz), the evolution of [hello-wo * [Q](q/q.q) * [Qbasic](q/Qbasic.bas) * [Qore](q/qore.q) +* [Qsharp](q/qsharp) * [Qu](q/qu.qu) * [Quakec](q/QuakeC.qc) * [Quartzcomposer](q/QuartzComposer.qtz) diff --git a/q/qsharp/Driver.cs b/q/qsharp/Driver.cs new file mode 100644 index 0000000..8f9445e --- /dev/null +++ b/q/qsharp/Driver.cs @@ -0,0 +1,19 @@ +using Microsoft.Quantum.Simulation.Simulators; + +namespace Quantum.HelloWorld +{ + class Driver + { + static void Main(string[] args) + { + using (var sim = new QuantumSimulator()) + { + var res = HelloWorld.Run(sim).Result; + System.Console.WriteLine( + $"{res}"); + } + System.Console.WriteLine("Press any key to continue..."); + System.Console.ReadKey(); + } + } +} \ No newline at end of file diff --git a/q/qsharp/qsharp.qs b/q/qsharp/qsharp.qs new file mode 100644 index 0000000..7c0ca89 --- /dev/null +++ b/q/qsharp/qsharp.qs @@ -0,0 +1,10 @@ +namespace Quantum.HelloWorld +{ + operation HelloWorld () : (String) + { + body + { + return ("Hello, World!"); + } + } +}