Cheating with Programming (?)

If you look around you, you’ll find that many everyday conveniences require some sort of programming to work. Everything from Facebook, refrigerators, cars, and even football games to the humble calculator and digital thermometer all involve some form of computer programming.

Computer programming is everywhere and will continue to grow. It’s so important and prevalent that some schools are even considering adding it to the standard curriculum. I think programming is something anyone could learn, but don’t necessarily think everyone would benefit from it, or even enjoy it. But if you’ve ever done a similar task more than a few times and found yourself wondering, “There’s got to be an easier way!”, then an investment of a few hours might save you time and effort in the long run.

In my high school math class, with my TI-83 calculator, I was told to memorize the quadratic formula. I would plug in a, b, and c, pencil through the steps to arrive at my answer. I knew the steps, but the process was the same every time; it was repetitive. I flipped through my TI-83 manual and learned how to save the formula, request a, b, and c as inputs, then have the calculator go through the steps for me and spit out x.

Now, I don’t know if my teacher would have approved of what I was doing, but I was working within the rules (calculators and number two pencil, only), and I didn’t have to spend time going through the same steps for every homework and test question. (Passing around the program also netted me a few $0.50 sugar cookies in the cafeteria!)

The point is, computers are better than us at fast, repetitive, logical, mathematical tasks; humans are better at everything else. When we offload these tasks to computers, we’re maximizing our efficiency, allowing us to focus on what we do well, and letting computers do their thing. So next time you do the same task two or three (or hundreds of) times, imagine having a computer do that for you. Wouldn’t your time investment in learning programming pay for itself over time if you were freed up from doing those tasks?

The other day I was shopping for savings accounts and wanted to know what kind of return I’d get on a certain monthly contribution ($500) at a certain interest rate (1.1%) over, say, thirty years. I found myself trying to the math in my head, but doing $500 times 12 months times 1.1% - thirty times - got exhausting pretty quickly. So I invested maybe 15 minutes and made a simple online tool to do this for me: a Simple Investment Calculator. Now I could tweak the numbers and spend zero seconds doing the math, allowing me to make the best decision and get on with my day. (You can see the code behind the simple investment calculator here, if you’re interested).

Later, I sat down to study Chinese. Having a hard time, I went online to look up the sounds. I’d look at my flash card, type in a rough English transliteration of the word, then click the speaker icon to hear it. Doing this 10, 20, or 30 times got pretty costly, time-wise. So I imagined how I wished it worked, and came up with a phone app so I could learn the way I wanted: Read Chinese.

Bill Wheeler, one of our programmers here at AYC, has examples of streamlining repetitive tasks, too: a browser tool to save bookmarks and organize them automatically. A simple, but useful tool, that over years may have saved a lot of time (and cat pictures).
If you’re interested in diving in with something easy, I created a Simple Greeting Page that you can tweak and edit to see a live example of programming; all you need is a web browser! You can change the variables to modify how the webpage program runs. The site is hosted on JS Bin, a live, online programming tool where you can create programs and webpages instantly: a great way to get started.

If you’re looking for a proper course and want to scratch the surface a bit, try the Code Academy JavaScript course (it’s free)!

There a lot of resources on the internet and at your local bookstore or library. So next time you have a problem that could be solved by leveraging the power a computer, jot it down and look into it! Your idea could be the next Facebook, Twitter, or iPhone! Heck, worst case scenario, you’ll learn something and save time.

Posted in Programming

Tagged Programming

Enjoy what you’re reading? Sign up for the AYC Media newsletter and receive updates on our posts.