Tuesday, March 12, 2013

Why Binary?


I was challenged by a parent last year about why we teach binary in our CS classes. Honestly I didn't answer too well. I was in a bit of shock, good shock - it is not often I have a parent have much of an idea about what we teach in CS.

So I didn't answer well. But I do teach it, and for very specific reasons.

Analog Binary Calculator


You have to be intentional about why you are teaching anything. Are you using it as a way of dividing the smart and the dumb kids? We might not state this as a goal, but often difficult topics in class create just this divide. This group gets it easily, so they are valued more than the kids that struggle. Think back to the last class you really struggled in and be honest - it can feel that way. As a non-speller this was a lot of my own elementary experience.

So as a community we have to move beyond teaching a skill for the sake of the skill. Frankly teaching something like binary is a bit of a cheap trick. Here are the steps you perform, practice those steps, now demonstrate mastery. Especially for those of us with a math education background this is exactly how we were taught to teach. To some degree this is training behavior, not teaching content.

CS gives us the opportunity to move beyond basic skills and give them context. We see this same issue happening in math. The kids don't get WHY they have to do fractions, so rather than provide a context, we hand them a calculator and move on. Most of them will never use it anyway, right? We rob them of a deeper understanding of their world when we take the easy route.

So, why do we bother with binary?

It is our job to constantly link these skills based topics back to the bigger questions of CS. Binary is foundational to understanding how computers act and what they can and cannot do.

So as you teach binary your students should be writing and answering questions. This is a perfect time to explore what kinds of problems computers can solve. Why is it fairly simple to search a cell phone's address book for your grandma's phone number, but you cannot just type in "solve world hunger" and get a solution? Well, part of the answer is the kinds of things computers can store. We can easily download Shakespeare's Hamlet, but we cannot get the computer to read it for us and list the major themes. That kind of processing is, for now, outside it's abilities.

And this is something students of any level can discuss. Perhaps not to the same depth or level of analysis, but they can form knowledge around it, and in fact they should.

And back to teaching the skill, it is also our job to teach difficult and abstract things with appropriate scaffolding so that all kids can get some level of mastery.  Again, not every kid will fully absorb the amazing beauty that is the two's comp algorithm, but if they have done it they will better understand why int x =/*insert hugemungous number*/ pops around and gives them a negative number. And maybe when that kid has gone off to college and is sitting in a very intimidating CS class they are that much less likely to drop it.

So for me binary is a cheap trick, but not for the skill's sake, but as a bridge to the bigger philosophical ideas that should be a part of CS education. Every person should be thinking about these things. It impacts us all.

2 comments:

  1. Nice observations. In a book I recently wrote about computing (for non-computer scientists), I debated how much to include about binary. It's important, but it's hard to make the topic interesting to someone with perhaps only a casual interest in the field. I ended up somewhere in the same neighborhood you are, I think: emphasizing a more abstract idea that encompasses binary. For me that abstract idea was encoding. We can encode information in discrete form, and that gives us enormous power. Further, it's something that people do every day without even thinking about it. Counting on your fingers, for example, is encoding a series of observations in digital form (literally :-).

    ReplyDelete
  2. Exactly - there's a reason there are no binary themed hit songs.

    I try to tie it to the idea of encoding...computers may be new, but humans have always needed to abstract information one way or another.

    Can't wait to see the book - sounds interesting!

    ReplyDelete

So, what do YOU think?