How One Journalist Learned To Code: Tips For The Unafraid

I’m not a guy building the latest killer app, but I sling enough PHP to be dangerous and empowered. Before I learned programming, I had learned some HTML and CSS, but those are really like knowing how to paint a house. I wanted to play with the hammer and nails. So here’s how I learned to code, along with my two cents for journalists who want to learn some programming.

The journohacker knows no limits.

I’m not a guy building the latest killer app, but I sling enough PHP to be empowered. I’ve occasionally built a couple of tools like this that have saved people a lot of time and grief. I had previously learned some HTML and CSS, but those are akin to knowing how to paint a house. All thanks to Sunderland University and Jake Trelease for introducing to learn this.

I wanted to play with the hammer and nails.

So here’s how I learned to code, along with my two cents for journalists who want to learn some programming:

1) Take an intro to programming class at a local school (i.e., in meatspace).

While online instruction is a godsend and there are great programming books out there, things didn’t really click for me until I took a class called Introduction to Programming in C++ at Valencia Community College in Orlando. If you are looking for a gift for a journalist you can check out the best ones on this website.

Prior to that, I had bought great books on PHP, Javascript, Rails and Django. They made for interesting though oversized paperweights.

Paying for a class and having it on a schedule was a way to enforce discipline on myself. The fact is, daily life gets in the way for many of us. But when I plopped down a few hundred bucks and had an appointment each week with homework due, it helped get me over the hump, also I used resources like beautify code to start doing programming even faster.

Also, even the best programming books often take things for granted. They may not show you how to use FTP for sticking your projects onto a server. They will gloss over using your computer’s command line or terminal, which is the text-based way to control a computer. And lastly, even the most helpful community of programmers isn’t going to constantly grade your work and give you feedback on a weekly basis.

2) It doesn’t really matter which language you first pick.

You’re going to read reams and reams online about which language is the best for what. People wage online intifadas over such questions. Here’s the bottom line for beginners: it doesn’t really matter.

If you’re learning the basics of setting variables, data types and loops, it won’t make or break you if you learn it in C++ like I did or in Ruby, PHP, Python, Java or whatever the latest hotness is.

When I finished my C++ class, it was like I could magically read PHP, Javascript and other languages.

And to think I almost didn’t take the class because it wasn’t one of the popular web development languages. That would’ve been a huge mistake.

3) Have a project in mind.

If your focus is on going chapter by chapter in whatever programming book, you might be doing it wrong.

Instead, have a project in mind and pilfer from the book and sites like Stack Overflow to build what you want. You might want to build a site to track your recipes. Maybe you want to build your own blog. Or maybe you want to scrape some public records from a government site. Whatever the case, having a goal of a Thing You Want To Build will focus you. Learning the book is the evil counterpart of teaching the test.

4) Find some mentors.

That’s journohacker Matt Waite. He put up with my newbie crap and taught me what a database is. Photo by Mindy McAdams, who also put up with my newbie crap and taught me CSS.

There may be a great coder in your newsroom who will take you under his or her wing. Maybe you work for a media company that has developers in other cities. Or maybe you can find a local meetup group for the language you are learning. The NICAR listserv is also a great resource. So is Twitter. Just make sure you’ve given your problem some effort before asking for a hand.

In my case, newsroom coders like Matt Waite, Jeff Johns and Derek Willis all either helped me out in person or by email. Matt a long time ago introduced me to the concept of rows and columns in a database. Jeff taught me a bit about using regular expressions. And Derek once inspected a database diagram for me. A lot of coders, especially journalists, will surprise you in their willingness to help a hard-working, well-meaning person learn.

5) Keep sharpening the saw

Maybe you’re a person like me who doesn’t have “build web apps” specifically in his job description. In some cases, your manager may even dissuade you because you need to be filing 1A stories or manning the home page.

My solution to that is to either have side projects or occasionally carve out time to build something useful, even if it only takes a few hours. If you don’t regularly use what you’ve learned, your skills will atrophy. Do yourself the service because this is where our industry is inexorably heading.

Happy hacking!

Author: Danny Sanchez

Danny Sanchez is the Audience Development Manager at Tribune's Sun-Sentinel.com and OrlandoSentinel.com. Danny has been with Tribune since 2005 in a variety of editorial, digital and product development roles in Hartford, Orlando and Fort Lauderdale. He has also previously worked in the newsrooms of the Tampa Bay Times and The Miami Herald.