It's a very, very old game.
Start at point 1, find a path through the maze. There are variants of this of course: one being which path through the maze goes through every part of the maze? Q*Bert was based on a similar idea - as your character progressed through a pyramid, as he jumped on various panels therein, they changed color - and your "level" was completed once every single panel had changed color. Various clones of Pac-Man had the same solution to that problem, changing the background color of a maze as you progressed through it, and you were "done" with that "level" once the maze had become the target color.
But Pac-Man had a different solution: representing the path through the maze with little dots that were "consumed" as he went through it, making a gobbling sound that soon was given the onomatopoeia "wocka wocka wocka".
Now - a maze game where all you did was traverse through it would be incredibly boring and technically only ever end when the player tired of doing so. So the game designer added in four "ghosts" - multicolored adversaries who killed you at a touch. They would wander the maze in a "random" fashion, but pursue Pac-Man if they figured out where he was. This would present the opposite problem - that the game would end rather rapidly as the player was simply killed by pursuing ghosts.
But not all dots were equal: four of them were "power pills" - larger dots that turned the ghosts blue for a short period of time, made them run FROM Pac-Man rather than TOWARDS him, and made them edible. While blue, the ghosts could be temporarily "killed" by being eaten, leaving only their "eyes" behind to seek resurrection at the middle of the maze. This bought the player either time to finish the maze without fear of being killed, or buy points - as eating each successive ghost upped the points reward. (it's powers of two times 100- 400, 800, 1600).
The term "Pac-Mania" was coined to describe the monster success of the game. It dominated both the gaming market in terms of money and sequels, but also mind share and branding. It spawned not only clones, sequels and home versions (everything from the Pac-Man cartridge to the Pac-Man watch game) but breakfast cereals, board games, toys, a Saturday morning cartoon, and additions to the lexicon. "Power Pill" is an expression, and even a nickname for Aphex Twin.
It was perfect for its time. It took advantage of the better resolutions and colors of burgeoning 1980s technology - replacing the mechanical "boinks" of games like Pong with music and sound effects, and updating moving monochromatic rectangles with colorful rounded shapes. But it wasn't so complex that the limits of the technology were apparent - such as in the case of games like Karate Master where the judge going "Full Point" sounds more like "FO POY" and the graphics look jagged and primary colored. It was in the ideal sweet spot in terms of using the technology without showing off its limitations.
It was also the selling point for many a game console - and the Atari 400 computer was notoriously sold in part for having a pretty close simulation of the arcade. Most other copies were terrible, most especially the Atari 2600 version. Having the equivalent to the arcade game at home was the ideal. Brad Paisley even famously sang in Welcome to the Future, "I'd have given everything to have my own Pac-Man game at home/Used to have to get a ride down to the arcade/Now I got it on my phone."
But of course, it couldn't be perfect. The paths of the ghosts weren't purely random - any randomizer back in the 1980s would have been quite predictable. And indeed, the ghosts followed predictable paths, and books were written and sold to explain how to exploit this by following specific paths through the maze at specific levels to "beat" the game. And the game could be beat - when the memory buffer allocated to score overran its boundary - it started to bleed over into the memory for the rest of the game, leading to very unpredictable results and the game malfunctioning.
And of course, to keep it interesting, they had to expand the franchise, to Ms. Pac-Man, a baby Pac-Man, a Super Pac Man, and so forth.
There have been a few theories as to why the game was so successful. Some pointed to the fact that it was based on one of the oldest games on earth, with mazes being something even today mowed into corn fields or created with very tall hedges in a garden - with admission charged to enter.
But my own personal take is that it epitomized everything about the 1980s. Colors were brighter and flashier. Guitars were starting to give way to synthesizers, and electronic music was starting to move out of the prog-rock, weird-avenue-of-jazz sort of thing a college professor would Switched-On Bach to and hit the streets. Malls were a thing, and acquiring property and money was very much in vogue. People started to hear about this mogul called "Donald Trump". People attended MBA graduation ceremonies in Ray-Ban Wayfarer sunglasses with signs that said "MBA = BMW", and the whole zeitgeist there was captured in American Psycho. So what better pastime could you think of but a darkened room containing an electronically-scored diversion in which the acquisition of "points" by rampant consumption was the key to success? In one small package, it managed to encapsulate the decade's tropes in one shot.