There is no “First” in CS1
Andy diSessa has a great video that he sometimes shows in his talks, where he is interviewing a Physics Senior at Berkeley. He’s asking her what happens to ball being tossed from one hand to the other. She tells him a story about potential and kinetic energy. He points out that the ball traces a parabola — what happens to cause that shape? She tells him a story about horizontal and vertical velocity, and about acceleration due to gravity impacting the vertical velocity, but not the horizontal. He presses her further — what really happens at the very top of the arc? What causes the ball to change direction? Finally, she blurts out, “The air pressure! The air pressure pushes down on the ball forcing it to fall!”
Which is wrong. It’s a common alternative conception for falling objects. The student was certainly not taught that explanation at Berkeley. She developed it as a novice, as an observer of the world around her. She chose to major in physics — she must have had an interest in the physical world before coming to Berkeley. She observed the physical world, and developed theories about how it worked. Andy’s video shows that, despite her developing new understanding, the old belief system is still there.
Cognitive science shows that no student enters our class a blank slate. They enter undergraduate study with nearly two decades of experience, and theories that they have developed in those decades about how the world works. Those theories have allowed them to function on a daily basis. If they enter our computer science classroom voluntarily, then they have probably been an astute observer of computing mechanisms, and they have certainly developed theories about how the computing world works.
I have heard proponents of a wide variety of beliefs about the power of CS1:
- “If we teach them recursion first, then iteration becomes simple.”
- “If we teach them strong typing (or test-driven development, or functional programming), then they will have good practices of mind that will stick with them for the rest of their years.”
- “If we teach them objects first, then objects will be natural to them. We all can’t understand it the same way, because we learned imperative programming first.”
- “It is practically impossible to teach good programming to students that have had a prior exposure to BASIC: as potential programmers they are mentally mutilated beyond hope of regeneration.” (You probably recognize this one.)
I don’t know if any of them were once true, but I’m quite confident that none of them are true today. There is no first. There is no objects-first, functions-first, hardware-first, or non-Basic-first. No, I’m not suggesting that there already is computer science in high school — there are way too few teachers and classes for that to be true, on average. Rather, in a world where students live with Facebook and WiFi and email and “To The Cloud,” they most certainly have theories about how computing works. There’s no way to get them before they make up their theories. By the time they decide to study computing, they have them.
I thought of this looking at Carsten Schulte’s ITICSE 2010 paper, on studying student perceptions of difficulty in an objects-first vs. an objects-later class. This is a follow-up to his earlier ICER paper where he reported no learning differences between an objects-first and an objects-later class. While I’ve heard complaints about Schulte’s analysis methods, I found his experimental set-up to be as careful as one could possibly be. The only difference between his two classes were the order of topics. Objects-first vs. objects-later doesn’t matter, but neither does any other -first. His results are really not surprising. We already know that the sequence of topics in a curriculum doesn’t really seem to make much difference in the learning — that’s how problem-based learning works.
It’s an important open research question: How do students understand the computing around them? What theories do they have?
- How do students explain how a router box works, that my daughters get Wikipedia when they ask for it and I get WordPress when I ask for it, though there’s only one DSL connection and one router box in the house?
- How do the Chinese characters appear on my screen when I get an email from China — were the characters in the email, or in my computer?
- How is it that I can run Windows on my MacBook?
- What is on that CD that I put into my Wii, and how is it different from what’s on a DVD or a CD that works on my Mac or PC?
We know something about how novices develop naive theories of computing. John Pane’s research shows us that novices tend to develop declarative explanations of software that is driven by events, and don’t seem to develop notions of objects at all. The “Commonsense Computing” group has shown us that novices can create algorithms for a variety of problems, though that doesn’t really tell us how they think software and software development works in the world around them.
One problem that we have as educators is that this is a constantly open research question. Every new technological doohickey that students meet will lead to new theories about how technology works, sometimes requiring changes to old theories. Our students will have different theories depending on their computing experiences. That’s how all learning works — we meet a new situation, that we either assimilate into our understanding, or that we accommodate with a new theory. Over 50 years of cognitive science tells us that this is happening with every student who is paying attention to computing. If they enter into our CS classes, they are paying attention, they are making sense of the world around them, and they already have theories about how their computing technology works, how software works, and how software is developed.
We are in the same position as physics (or biology, or chemistry, or other science) educators. Students have theories about how Wii controllers, voicemail menu systems driven by spoken voice commands, touch screens, and Google/Bing search work. If these novice theories “mutilate” their minds, then it’s done, it’s happened to everyone, and we’d best just get on dealing with it. There is no chance to place a theory in their minds before they learn anything else. We have to start from where the students are, and help them develop better theories which are more consistent and more correct theories. There is no first, but we can influence next.