Imagine it’s Friday evening. After a whole week of work or study, you deserve a moment to relax. You make a cup of tea, settle in comfortably in front of your computer and launch a game to unwind.
You’ve heard that IBM has recently made its quantum computers available online, and Steam has prepared a special plugin for them. Curious, you switch it on.
The game starts as usual. The intro looks great. Meanwhile, you check the estimated playtime.

Everything checks out, it’s shaping up to be a perfect weekend… . . Suddenly, the end screen!

Congratulations! You have completed every possible scenario in 15 nanoseconds.
You stare blankly at the screen. The tea is still steaming. Not great. The only upside is that you still have the whole weekend ahead of you. You wonder what went wrong. You suspect it was that quantum computer plugin that overdid things. And… you’re right.
AI interview
If you’d like to listen to the article as audio, in the form of an interview, check it out on YouTube:
How does a quantum computer work?
This story, although exaggerated, captures quite well the way a quantum computer works. Instead of going through scenarios one step at a time, a quantum computer considers all possible paths at once, in a single run. With the right setup, it can also answer questions like: “Which scenario is the longest?”.
Will quantum PCs replace our computers?
Probably not. Quantum computers will find specialised applications and will be a separate component of a digital computer. Much like today’s graphics cards, which, as the name suggests, are used… among other things, to mine cryptocurrencies or train artificial intelligence models. 😉
And will they be used in games? Probably, yes. Though not necessarily in a way that takes the fun out of playing ;-). Imagine dynamic, changing worlds that never repeat the same scenarios, NPCs that adapt to the player’s behaviour, or realistic physics simulation.
Disclaimer

In this article I use various examples, metaphors and humorous stories meant to spark your imagination and bring closer the difficult subject of how quantum computers work and the principles of quantum mechanics.
They shouldn’t be taken literally, though. Use them instead to stretch your imagination and look for hints and analogies. The quantum world follows completely different rules from the classical world we experience every day. The quantum one is less intuitive and harder to understand. As Richard Feynman once said:
“If you think you understand quantum mechanics, you don’t understand quantum mechanics.”
Quantum mechanics
If we want to understand how quantum computers work, we have to dive, at least for a moment, into the world of quantum mechanics.
Don’t worry, there will be no maths and no Greek letters :). Instead, I’ll try to tell some interesting stories about how scientists tried to get their heads around something that escaped their imagination.
Do you need to know quantum mechanics to get to grips with quantum computers? Well… Not necessarily, since you don’t need to understand the theory of relativity to use GPS either. However, at the current stage of development and deployment of quantum technology, you can’t really do without physics. But it’s rather interesting physics.
The illustration below shows one of the best-known equations of quantum mechanics: the Schrödinger equation. It tells us how an object changes over time and what can happen to it. Don’t worry, it’s the only formula I’ll show in this article 😉.

The ultraviolet catastrophe
But how did it all begin? Well, it began with a catastrophe, or more precisely, the ultraviolet catastrophe.
Nineteenth-century physicists had a serious problem with the so-called black body. What is a black body? It’s an ideal black cavity, something like a closed box with a small hole, that absorbs and emits radiation. Like the one shown below.

According to the theory of the time, if you heat such a body, it should emit light. But something didn’t add up. For short wavelengths, that is in the ultraviolet, the intensity grew… to infinity.
This leads to what’s called a singularity. And physicists don’t like singularities, because they don’t know what happens there.
Quanta
In 1900, after five years of struggling with this problem, Max Planck proposed something completely new:
Maybe energy is not continuous? Maybe it only comes in small portions - quanta?

And that was the breakthrough. He revolutionised physics with a single equation, E=hv. (This really is the last formula :)). He introduced the so-called “Planck constant” and denoted it with the letter h. I’ve heard an amusing anecdote that it comes from the German Hilfe, meaning “help”, because, as he himself said, the theory was an act of desperation.
And so quantum physics was born.
The most intelligent photo in human history
Over the next two decades, the quantum revolution gathered pace. Like any revolution, it stirred up plenty of emotions and extreme positions. Some of the best-known physicists of the time, Schrödinger, Heisenberg, Dirac, Bohr and Born, developed the concept and created formal notation and equations.
Scientists discussed their work and debated at conferences. The most famous of these was the one held in Solvay.
That’s where the legendary debate between Einstein and Niels Bohr about the interpretation of quantum mechanics took place. Einstein could not accept that something could be “random” by nature. Later, in a letter to Born, he even wrote “God does not play dice”. To which, on another occasion, Bohr retorted “Stop telling God what to do” ;).
In 1935, together with his students Podolsky and Rosen, he presented the so-called EPR paradox, trying to prove that quantum theory was incomplete, or even wrong, despite agreeing with experiments.

This is the legendary photo from the Solvay Conference, showing the cream of physics at the time. 29 people in one photo, 17 of whom later received the Nobel Prize. The photograph is often called “the most intelligent photo in history”. Note the only woman in the picture, who was also Polish: Maria Skłodowska-Curie.
Classical computers
When quantum mechanics was being born, the electronic computer did not yet exist. But less than 50 years later, the first huge machines were being built and installed in research laboratories. The photo below shows an example of such a supercomputer, the Cray-1. Looking at it, you have to admit it looks futuristic even by today’s standards… just like today’s quantum computers.

In the 1980s, personal computers entered the market and quickly made their way into ordinary homes. That’s when marvels like the Apple II, Commodore 64 and ZX Spectrum appeared. Computers were already powerful enough to do more than play games. By then they were also supporting business and finance. And of course they were used in scientific research.

Even though computing power grew year after year, in line with Moore’s law, scientists noticed that some problems could not be solved by adding more and more transistors. It didn’t scale with their problems and questions. Because nature doesn’t work like a classical computer, and we will never build enough transistors to simulate every simple natural process. In fact, there isn’t even enough silicon on Earth, and besides, there wouldn’t be enough space and energy in the universe ;).
Nobel laureate Richard Feynman made this point forcefully in 1981 at a conference at MIT. That’s when he uttered the now-legendary sentence: “Nature isn’t classical, dammit, and if you want to make a simulation of nature, you’d better make it quantum mechanical.” And he added: “and by golly it’s a wonderful problem, because it doesn’t look so easy.”

What he meant was that we need to build a computing system that grows linearly with the complexity of the problem. Although Feynman only threw out the idea and didn’t create any concrete design for a quantum computer, it was a breakthrough moment in history, and his words are often considered the symbolic beginning of the field.
The father of quantum computers, however, is considered to be David Deutsch of the University of Oxford, who in 1985 formally described how a quantum computer should work.

What’s more, he came up with the first algorithm, known today as the Deutsch-Jozsa algorithm, which served as a test for the proposed design and was meant to show that such a computer could actually work and, most importantly, outperform classical machines. It looks like solid software engineering, almost TDD ;)
The algorithm was fairly simple: its task was to check whether a given function is constant, that is, always returns the same result, or balanced, that is, returns 0 for half of the inputs and 1 for the other half. A classical computer would have to check many cases, while a quantum one does it in a single step. In other words, it solves the problem in one run. Just like our game in the introduction was solved.
To illustrate this problem more vividly, we can once again use an example from the world of Fallout. Imagine you’re Vault Boy from Fallout, stepping out of the vault. It’s quiet everywhere, and nobody knows whether the world has survived. To find out, you’d have to call every NPC, but you don’t have time for that, because radiation!

Luckily, you have a quantum phone with Deutsch’s algorithm. You send a single query to all the NPCs at once and immediately get an answer encoded in quantum phases. You read it and you already know whether everyone is alive.
The algorithm wasn’t particularly practical, but it showed enormous potential and demonstrated that the design could work.
The first practical algorithm that really caused a stir, however, was Shor’s algorithm from 1994.

It is used to factor numbers into primes. And that explains why it attracted so much interest. Why is it so interesting? Because modern encryption (e.g. RSA) relies precisely on the fact that recovering the prime factors used for encryption is very, very hard, or rather, not so much hard as time-consuming. If a quantum computer could factor huge numbers, it could break many of today’s security systems.
When Shor presented his algorithm, the reactions were mixed. A brilliant idea, sure, but… there were no computers that could run it. Many considered quantum computers to be pure theoretical speculation.
Until 1995, when David Wineland created the first working qubit. He used a single ion confined in a trap made of electromagnetic fields. For this achievement he received the Nobel Prize in 2012. From that moment on, we moved from theory to practice.

Of course, keeping an ion in an electromagnetic trap is no simple matter. Imagine a ball balancing on a saddle that you have to keep in equilibrium by rotating and manipulating the saddle. That’s what stabilising a qubit looks like; it’s a very dynamic task.
And here’s a keyword: qubit. What exactly is it?

A classical computer processes information using bits. And a bit is 0 or 1. A bit is a container for a zero or a one. Simple.
A quantum computer processes information using qubits. And a qubit is 0 and 1 at the same time! A qubit is a container for storing a superposition of 0 and 1.
And here’s the second keyword: superposition.
Superposition is a property of quantum objects: as long as nobody is looking at them, they are in many states at once. Schrödinger’s cat is the classic example: until you open the box, it is both alive and dead. An electron can have spin up and spin down at the same time.

This behaviour is described by the wave function, which we saw in the Schrödinger equation at the very beginning. It tells us the probability of reading each state. A measurement forces the object under study to choose one state; its wave function then collapses and the superposition disappears. The resulting state itself is completely random, but it follows the probability distribution given by the wave function.
Einstein sometimes poked fun at this principle and asked guests who visited him in the evening:
“Is the Moon there only because my cat is looking at it?”
David Deutsch, the one behind the quantum computer design, went further and suggested that the observer could be not a human, but… artificial intelligence. Interesting, isn’t it? Especially today, when AI is developing at such a pace.
A real-life example of superposition? My son caught a cold. My wife says: “It’s because you said he’d definitely get sick!” And I say: “So if I hadn’t said it, he wouldn’t have caught a cold?” And she says: “Exactly! It’s like your physics: until you say something, it doesn’t exist!” 😄
Another popular analogy is a spinning coin. A coin lying flat is a classical bit: heads or tails. And a spinning coin? That’s a qubit in superposition; only when you stop it, that is, take a measurement, does it show a result.

And that’s exactly what programming quantum computers is about. We manipulate the wave function so as to change the superposition of individual qubits in order to change the probability of getting 0 or 1. Or, put simply: we spin the coin so that it lands heads more often than tails.
Back to Wineland. We already know how he kept the ion in the trap, but how did he put it into superposition? He did it by firing a laser at it with great precision. This caused oscillations between two energy levels: the excited state and the ground state. These levels corresponded to 0 and 1.

And that’s how the first physical qubit was created.
Wineland proved that quantum computers could be built in practice. Admittedly, there was still a long way to go from a single qubit to a system that could run an algorithm, but it put fresh wind in scientists’ sails, and despite the lack of physical hardware, the fascination with quantum computing kept growing.
In 1996, the second best-known quantum algorithm appeared: Grover’s algorithm. What was its main purpose? Finding a specific element in an unordered data set.

This algorithm once again demonstrated the advantage of quantum computing over classical computing. Because, as Grover showed, its complexity is the square root of N. So if you have a million elements, instead of a million steps as in the classical approach, about a thousand are enough. That’s an enormous speed-up. In the classical approach you have to check element after element until you hit the right one. In the worst case, you’ll only stop at the very last one. Here we have a quantum shortcut.
The obvious applications are searching unindexed databases and speeding up machine learning processes. However, there were also voices that this algorithm could weaken existing digital security. Specifically, password cracking. If you have a dictionary password and you just need to test every possibility, Grover will speed up the whole process.
How can we compare Shor’s and Grover’s algorithms in an interesting way? We could picture it like this.

Shor is like a brilliant mathematician who analyses the problem and elegantly derives the solution. He has his beautiful mathematical apparatus to work with. And Grover? He’s brute force, raw power with a turbocharger. He doesn’t look for an elegant solution, he just checks every option, but does it in a flash.
We’ve now met three quantum algorithms, so the natural question is: what does their implementation actually look like?
The illustration below shows an example in which I implemented Grover’s algorithm on a quantum computer.

This particular case shows how to find one element in a set of eight. We won’t go into the technical details now, but a few things are worth noting.
First, the first three horizontal lines are qubits. The last one is the readout line, that is, what we collect from the qubits after the computation is done and their wave function has collapsed. All those little squares on the lines are logic gates. Just as classical electronics has gates like NAND, OR and NOT, it’s similar here, only in a quantum version.
Particularly interesting are the gates that look like brown squares with the letter H. These are Hadamard gates. Their job is to put qubits into a perfect superposition, meaning the qubit becomes both zero and one at the same time. It’s thanks to them that a quantum computer can test all possibilities at once.
The other interesting gates are the green ones with an X or a plus. They connect different qubits to each other. This is something classical computers don’t have: they let qubits interact and “communicate with each other”. They introduce quantum entanglement. And that, in turn, makes the result of the computation depend on all the qubits at once.
These are the foundations quantum algorithms are built on: a bit of maths, a bit of physics, and the rest is the magic of superposition and entanglement.
In the second part of the article we’ll look at the other key phenomenon of quantum mechanics that makes quantum computers work: quantum entanglement. We’ll also see what the quantum computers being built today look like and whether they really are more efficient than classical computers.
Comments and social media
You made it all the way here? :) I’m really glad 🤸🏻♀️. Have some thoughts? Know an interesting example or want to ask something? Leave a comment or like my post on social media – I’d really appreciate it!
AI interview
You can also listen to an AI-generated interview based on this article:
List of figures
- Title image generated by the author using AI tools.
- Fig. 1: The game - generated by the author using AI tools.
- Fig. 2: Game over with a quantum computer’s help - generated by the author using AI tools.
- Fig. 3: A graphics card farm - generated by the author using AI tools.
- Fig. 4: Quantum Disclaimer - created by the author.
- Fig. 5: The Schrödinger equation - generated by the author using AI tools.
- Fig. 6: A black body - Wikimedia
- Fig. 7: Max Planck - based on a 1933 photo of Max Planck, Wikimedia Commons/public domain
- Fig. 8: The Solvay Conference, 1927 -
- Fig. 9: The Cray-1 supercomputer - Linuxadictos
- Fig. 10: IBM PC advertisement - PCMAG
- Fig. 11: Richard Feynman -
- Fig. 12: David Deutsch - the father of quantum computers - based on a frame from the video David Deutsch - What is Ultimate Reality? Closer To Truth
- Fig. 13: The quantum phone - generated by the author using AI tools.
- Fig. 14: Peter Shor - quantum prime factorisation - based on a frame from the video Quantum Expert Insight: Peter Shor Qiskit
- Fig. 15: David Wineland - the first qubit - based on a frame from the video Ion Trapping - Dr. David Wineland Institute for Quantum Computing
- Fig. 16: Bit vs Qubit - generated by the author using AI tools.
- Fig. 17: Superposition is 0 and 1 at the same time - generated by the author using AI tools.
- Fig. 18: A spinning coin from Fallout - another illustration of superposition - generated by the author using AI tools.
- Fig. 19: The ion’s high and low energy states correspond to 0 or 1 - generated by the author using AI tools.
- Fig. 20: Grover - the search algorithm -
- Fig. 21: Shor vs Grover - generated by the author using AI tools.
- Fig. 22: A quantum implementation of Grover’s algorithm - created by the author.
The article and the illustrations I generated with AI are released under the Creative Commons Attribution 4.0 International license. You are free to copy, quote and modify the text and graphics, provided you clearly credit the source: “Łukasz Herok and a link to this page”.



