12 Wordles Inside a Soccer Ball
Situation
Albert was building a soccer ball in p5.js.
At the beginning of class, his ball already had 20 gray, transparent hexagons โ and 12 empty pentagons.
Albert looked at it and immediately said:
โThe pentagons should be black while the eh ... should be white.โ
I supplied the missing word:
โHexagons?โ
โAh, yes, hexagons.โ ๐
So he changed the white background to gray, making the hexagons white and the pentagons black.
But the real puzzle was still waiting.
Turning Point
Each pentagon needed five vertices in the correct order so that Albert could draw it with beginShape().
There were twelve pentagons.
Twelve little puzzles.
And suddenly Albert remembered a game I had introduced to him years ago.
Neither of us could remember its name.
It took us three hours to recover it.
Wordle. ๐
So Albert spent part of his programming class playing twelve rounds of Wordle โ except his โwordsโ were five vertex numbers.
For every pentagon, he had to figure out:
Which five vertices? And in what order?
A wrong order produced a strange shape.
A correct order produced a beautiful black pentagon.
And, just like Wordle, each solved puzzle gave him experience for the next one.
Albert became faster and faster.
Emergence
Then came the really interesting moment.
Albert had an earlier piece of code that he might eventually delete:
function drawAllThirds() {
let vertices = [
[0,3], [0,4], [0,5], [0,8], [0,10],
[1,2], [1,6], [1,7], [1,8], [1,10],
...
];
for (let v of vertices) {
drawPairThird(v[0], v[1]);
}
}
I asked:
โWait a moment. Are they just edges? But we use the name vertices.โ
Albert thought about it and explained that they were the vertices of the soccer ball โ pairs of vertex numbers used to draw the two third-points on each edge.
He was right.
I was looking at the 30 edges connecting the 12 vertices of the original icosahedron.
Albert was looking at the pairs of vertices used by his program.
Same structure. Two ways of seeing it.
And then Albert realized something wonderful:
This old structure could give him clues for solving the pentagons.
The code he might delete had already encoded part of the geometry he needed.
He didn't need to start from nothing.
His own program was giving him hints.
Learning
Albert's soccer ball became much more than a graphics exercise.
He discovered that:
a geometric object can be represented by data;
the same data can be viewed in different ways;
existing code can contain useful knowledge even when it was written for another purpose;
a difficult problem can become easier when we find the right clues;
and repeated attempts can lead to better and faster strategies.
Most importantly, he experienced something programmers eventually learn over and over:
Sometimes the breakthrough comes not from writing more code, but from looking differently at the code you already have.
Theme
Learning to see the structure inside the structure.
Albert began with a soccer ball made of hexagons and empty pentagons.
He ended with twelve little Wordle puzzles, thirty edges, twelve vertices, and a new way of reading his own program.
The soccer ball was not just something he was drawing.
It was teaching him how to think.
What Is Possible?
A soccer ball can become a geometry problem.
A geometry problem can become a programming problem.
And a programming problem can become a game.
How Does It Happen?
Look at what you already have.
Find the structure.
Use it as a clue.
Try.
Learn from the result.
Try again.
Why Does It Matter?
Because sometimes the most useful information is already sitting inside your program โ waiting for you to notice it.