SkillAgentSearch skills...

QuantumKatas

Tutorials and programming exercises for learning Q# and quantum computing

Install / Use

/learn @microsoft/QuantumKatas

README

DEPRECATION NOTICE

We are modernizing the quantum katas experience. Please visit https://quantum.microsoft.com/experience/quantum-katas to try the new online Azure Quantum katas experience, with integrated assistance from Copilot in Azure Quantum.

For the Modern QDK repository, please visit Microsoft/qsharp.

For more information about the Modern QDK and Azure Quantum, visit https://aka.ms/AQ/Documentation.

Introduction

The Quantum Katas are a collection of self-paced tutorials and programming exercises to help you learn quantum computing and Q# programming.

Each kata is a separate set of exercises that includes:

  • A sequence of tasks progressing from easy to hard. Each task requires you to fill in some code. The first task might require just one line, and the last one might require rather complicated code.
  • A testing framework that sets up, runs, and validates your solutions. Each task is covered by a unit test which initially fails. Once you write the code to make the test pass, you can move on to the next task.
  • Links to quantum computing and Q# reference material you might need to solve the tasks.
  • Hints, reference solutions and detailed explanations to help you if you're stuck.

The Quantum Katas also include tutorials that introduce the learner to the basic concepts and algorithms used in quantum computing, starting with the necessary math (complex numbers and linear algebra). They follow the same pattern of supplementing the theory with Q# demos and hands-on programming exercises.

Table of contents

Learning path <a name="learning-path" />

Here is the learning path we suggest you to follow if you are starting to learn quantum computing and quantum programming. Once you're comfortable with the basics, you're welcome to jump ahead to the topics that pique your interest!

Quantum Computing Concepts: Qubits and Gates

Quantum Computing Concepts: Measurements

Q# and Microsoft Quantum Development Kit Tools

Simple Algorithms

Quantum Oracles and Simple Oracle Algorithms

Grover's Search Algorithm

Tools and Libraries/Building up to Shor's Algorithm

Entanglement Games

Reversible Computing

  • Truth tables. Learn to represent and manipulate Boolean functions as truth tables and to implement them as quantum operations.
  • Ripple-carry adder. Build a ripple-carry adder on a quantum computer.

Miscellaneous

For a Q# programming language quick reference sheet, see Q# Language Quick Reference.

Run the katas and tutorials online <a name="run-online" />

The Quantum Katas are now available as Jupyter Notebooks online! See index.ipynb for the list of all katas and tutorials, and instructions for running them online.

Note that mybinder.org is running with reduced capacity, so getting a virtual machine and launching the notebooks on it might take several attempts. While running the Katas online is the easiest option to get started, if you want to save your progress and enjoy better performance, we recommend you to choose the local setup option.

Run the katas locally <a name="kata-locally" />

Quantum Development Kit Installation <a name="install" />

To use the Quantum Katas locally, you'll need the Quantum Development Kit, available for Windows 10, macOS, and Linux. If you don't already have the Quantum Development Kit installed, see the install guide for the Quantum Development Kit.

If you want to run the katas and tutorials locally as Jupyter Notebooks:

  1. Follow the steps in the QDK install guide for Python and the QDK install guide for Jupyter Notebooks.
  2. Several tutorials require installing additional Python packages:
    • "Complex arithmetic" and "Linear algebra" require the pytest package.
    • "Exploring Grover's search algorithm" requires the [matplotlib package](https://m
View on GitHub
GitHub Stars4.8k
CategoryEducation
Updated1d ago
Forks1.2k

Languages

Jupyter Notebook

Security Score

100/100

Audited on Mar 28, 2026

No findings