There is a fun anime series called One Punch Man. Surprisingly, it has some great lessons for mastering Python.
The story takes place in a world more modern than our own, where the heroes defend the modern city landscape from invading monsters regularly. Imagine a parade of miniature creatures Godzilla or Mothra, but they are more diverse, colorful and intelligent, and range widely in size and threat level.
This continues to the point where a formal league of champions is formed, with ranks for different perceived skills. Enter the hero named Saitama.
He’s not as flashy as the other heroes.
If anything, it seems at first glance harmless.
But it turned out to be very effective as a martial artist, unparalleled in his skill, being able to hit huge powerful monsters with one punch, at a time. Hence the name.
This show is comical, full of hilarious situations created by the hero-run establishments that fail to recognize his super talent over and over again. I’ll leave a lot more here – it’s worth digging in and watching.
But the show does provide a powerful lesson for us like Pythonistas.
Because the source of Saitama’s mastery is revealed in season one. He did it every day without fail
- 100 pushups.
- 100 sit-ups.
- 100 squats.
- Then he ran ten kilometers.
Notice how simple this is.
He drills these core drills with relentless consistency. And somehow, I managed to unlock a super skill.
This reminds me of what happens when you master the basics of Python programming.
OOP, for example. Because OOP is the critical foundation upon which all complex software is built. A little OOP knowledge goes a long way…but greater understanding unlocks both new software for you.
Or automated tests, such as unit tests. When you master writing these things, you can suddenly create shockingly powerful software systems that untested writers can’t touch. Writing tests are a legitimate superpower.
Another interesting point: when you master both, you find that they increase each other’s strength. OOP amplifies what you can do with tests, and vice versa, in exponential ways that suddenly makes the nice programming you’ve done before seem primitive and simple.
And then you have scalability patterns that take advantage of the Python memory model… or the abstractions of higher-level functions that form the bedrock of the dozens of popular Python libraries you use every day… and so on.
Each of these are like push-ups or squats that Saitama does religiously.
And all of this is just one lesson we can learn from our friend Saitama. There are many other things: like how he always goes straight to a monster’s weak spot (I know you can see a parallel counterpart to complex software “monsters”)… or how he’s constantly looking for a bigger challenge to test himself and grow… . And many other lessons.
So look up this show, or read the manga it’s based on. And look for other lessons that you can take advantage of to improve your coding craft.