Enough to Be Dangerous: The Joy of Bad Python
Learning to Code is all the rage. I don't see any sign that the trend is dying down any time soon. I might as well jump on the bandwagon here and encourage my fellow tech writers to do the same.
Obviously, a lot of you already code, or are in the process of learning. I once assumed knowing at least some coding was a requirement for being a tech writer. But it seems this isn't entirely the case. Some TWs need to be able to read and write enough code to document APIs and provide code samples --- but apparently (I have learned) most tech writers aren't doing that, and you can fake your way through that if you really need to.
So, if you are among the majority of technical writers that don't code, this post is for you.
We Know Too Much
When people outside the tech field suddenly decide that they are going to learn to code, they have no idea how hard that actually is. All of the "Learn to Code" resources, books, sites, and bootcamps tell you that you can learn to build web and mobile apps pretty easily --- in just a few weeks, even.
And when you first start coding, it seems magical. Especially if the framework does a lot for you. "Oh, wow! Is this all it takes to build an app?!"
You and I know --- these people don't have any idea what they are in for, how difficult it is about to get for them, how far is the distance between local build and production deployment.
I suspect this stops many of us from getting started. It stopped me for a long time.
Beginner's mind is a state in which, lacking the knowledge of how hard something is, everything seems easy. There are no boundaries, only possibilities. Beginner's mind is crucial for early learning of a new skill or subject area. With beginner's mind, small improvements seem like major wins. This enthusiasm creates a positive feedback loop, encouraging more learning and skill acquisition.
Tech writers don't have beginner's mind. Even if you have never written a line of code in your life, our proximity to software development has shattered any illusions we might have about how easy it is to get an app built and launched. We are aware of all the things that beginners happily ignore --- security, maintainability, deployment, cross-platform compatibility. We've seen too many problems caused by ignoring things. If we ever do sit down to start building a little app or follow along with a tutorial, we are overwhelmed by all the things that are going unmentioned.
Or maybe I'm the only one.
Don't Hope to be a Developer
Here's my trick for overcoming this problem --- drastically lower your expectations of what "learning to code" means.
You already know how hard it is to go from zero (or even 1) to actually-qualified developer. And you've met too many not-actually-qualified developers to have any interest in that path.
So how do you get started?
By deciding you are not ever going to write any application code. You are not going to be a developer. You are not even going to be a "coder."
You are going to be a technical writer with bad coding skills.
That lowers the bar, doesn't it?
Bad Coding Skills
What are you going to do with bad coding skills?
You're not going to become a developer with bad coding skills. (That's not an editorial "you." Lots of people become developers with bad coding skills. You, in particular, are not going to become a developer with bad coding skills.)
You are going to be a better technical writer. More efficient, happier, and more employable.
Here a few things I have been able to do since acquiring bad coding skills:
- semi-automate an incredibly boring freelance writing task, letting me earn the same amount of money in about half the time
- easily render HTML from Markdown, automating fussy style rules and naming conventions, saving several minutes and annoyance every day
- switch from WordPress to Jekyll and/or Nikola for my personal blogs, saving money and time
- put "Python" on my resume, greatly increasing the number of interviews and job opportunities I get
- automate documentation deployment ("DocOps")
- write code samples where I actually knew what was going on
- make a code contribution to an Open Source project
I have not built any apps or launched any products. No one has ever paid me to write code, and I don't think anyone ever will. I don't know how to handle user sessions or deal with cache invalidation. I code slowly, and I Google constantly.
And, believe me, the code I have written is bad. It's ugly and inefficient. It wouldn't pass a code review.
But, even though my coding skills are bad, they have made a huge impact in my life. I am more employable, more efficient, more valuable. I'm also happier, and feel more optimistic about my future. Bad code works.
If you have been discouraged, I encourage you. It only takes a little bit --- enough to be dangerous.
Programming as a profession is only moderately interesting. It can be a good job, but you could make about the same money and be happier running a fast food joint. You're much better off using code as your secret weapon in another profession.
People who can code in the world of technology companies are a dime a dozen and get no respect. People who can code in biology, medicine, government, sociology, physics, history, and mathematics are respected and can do amazing things to advance those disciplines.
--- Zed Shaw, Learn Python the Hard Way
How (What) To Learn
I recommend Python.
Python is the perfect language for bad coding by non-developers. You can do a lot without knowing very much, and there are a lot of tools for accomplishing non-development tasks --- writing tools, math tools, publishing tools, task automation tools. If you're going to learn to code in order to improve your own life (as opposed to learning to code to get a job or build things) Python is the best option. (It's also good for getting jobs and building things. Learning Python will not limit you.)
I do not recommend Learn Python the Hard Way, even though it is very popular. It's out of date and a bit too curmudgeonly.
The best book (I think) for learning to write Python for life-improvement is Automate the Boring Stuff with Python.
CommentsComments powered by Disqus