// you’re reading...

Education

What Computer Science could borrow from the English class

bubble sort poetry

There is something that I have noticed about students studying for Computer Science tests, especially at the high school level – it seems that many study to pass the test, but not to understand the concepts involved. It’s a ridiculous scene – watching students pace down the hallway before an exam, reciting bubble sort (and if they make it to University, linked list patterns) as poetry. And while I would also argue that computer programming has certain poetic features to it, such static regurgitation of a memorized fact serves little practical value.

Programming is poetry. Computer programming is a creative expression of unambiguous logical thought. Such expression is bound by the limits of the language’s syntax as much as English poetry is bound by the rhyming
vocabulary of the written language. Though when it comes to English, the poems are not simply recited, but analyzed and discussed as well. The latter points seem to lack in the computer science classrooms.

It seems that technical content takes preference over creativity and logic – pillar fundamentals of computer science. When students concentrate on memorizing oddities of specific syntax structure, the larger picture of a concept behind the coded expression is being lost. The situation arises from students’ lack of complete understanding of the complex and strict languages, frustration of getting things to work “just right”, and is re-enforced by cookie-cutter technical assignments and tests. Some simply give up, memorize the pattern that they are told will be on the test, and… pass. Decent grades paint a very misleading picture of classroom’s achievements.

So what could be done? Clayton weighted in with his articles on Keeping students interested in Computer Science and part two. In the latter post, he talked about challenging oneself with some programming contests, and that is actually an excellent measure of understanding. I have seen a promising student carry a solid 90% average in the computer science class, yet showed an unexpectedly poor performance during the Canadian Computing Competition when the non-trivial questions took him out of the classroom’s comfort zone.

Computer Science classrooms absolutely should borrow from the English class. Encourage creativity and logic outside of the technical frustrations. English language is fairly forgiving, such that spelling and grammar mistakes still allow for an insightful paper to be produced. Programming assignments should be more like essays – much more free form, much more creative, with analysis and discussion. Programming is only the practical application of the material, we should concentrate on the science and art parts of the subject.

University assignments that ask to write a “program” via filling out the function stubs provided by TAs carry as much utility as spelling tests we used to have in the elementary school. It’s time for computer science to grow up.

Read more

Discussion

  1. Posted by Mike Minutillo | May 11, 2007, 9:27 am

    I think that the main reason that people are able to perform in the free-er environment of english assignments is not because of a fundamental difference in the subject matter. I think that it is instead caused by the student’s exposure to the subject matter up to that point.

    By the time some people get to their first class CompSci class, they might never have written code before. Compare this to english class where you only get to write essays after you have been exposed to the material for years. It takes you 10 years (or so I can’t be bothered actually figuring it out) of speaking english before you just get to the point of being able to begin writing complicated, well-reasoned essays.

    Computer Science might seem like it is in it’s early childhood, but that’s because by the time you’ve finished College you’ve learned the alphabet and you can use three-syllable words without your brain melting (to juxtapose the two fields). You are by no means William Shakespeare yet.

    Wrote-learning (Rote?) is rampant in most fields. It really exposes someone who is more concerned with getting the grades (so they can brag, get the high $’s, justify themselves to their parents, etc.) than they are with learning the material. You will have a hard time getting them excited about CS again. It all comes back to the previous post about making CompSci fun and exciting I guess.

    *takes breath and runs out of ideas*

    Reply to comment

  2. Posted by Tony | May 11, 2007, 11:06 am

    Excellent points Mike, though the experience of “written code” is given way too much emphasis. Students have had the same 10 years of experience with logic, math, and to a lesser degree – scientific approach.

    Could the concept of a repeated task, until a condition is met, be explained without using the term for loop or a paramount concern of how many semi-colons it requires?

    I’ve heard of Computer Science classes where the same material was taught in grades 10, 11, and 12 – just with a different programming languages each year. Great, kids will know how to write “for loop” in 3 different ways, and still not understand as to why.

    Reply to comment

  3. Posted by Mike Minutillo | May 11, 2007, 8:22 pm

    I agree that writing code is a small part of Computer Science but it is a very important one. It is the language that is used to convey higher-level constructs.

    I definitely agree that the survey of languages is a terrible way to learn. It confuses new people and leaves them with no real understanding of anything.

    The problem with that is that they will learn the ruby way or the C way of doing things and they will pick up some very bad habits which will eventually lead them to write C code in LISP (OK so that’s a stretch but you get the idea).

    Is it possible to teach these concepts without coding? I’ve always liked the tactile approach of getting a bunch of people to be data and then some other person to organize that data somehow and then describe how they do it. Getting students to “discover” bubble-sort this way is awesome fun.

    Reply to comment

  4. Posted by Konstantin Lopyrev | May 12, 2007, 12:28 pm

    I agree entirely with what you are saying. Just learning the syntax of a language doesn’t teach you anything about computer science. Computer Science is more about problem solving and algorithms, than pure coding. Nobody wants to end up being a code monkey, but that’s what I see computer science classes teaching you sometimes. I remember that in grade 10, I decided to skip the grade 10 computer science course and go to the grade 11 one. Boy, that was a smart dicision. Besides being particularly slow, my computer science teacher was very good in that he focused on more than just writing code. I remember that the very first assignment he gave everyone taking the course had nothing to do with programming. It was purely problem solving. When I took the grade 12 class, we spent a lot of time learning algorithms and data structures. The teacher assumed that you know most of the syntax already and didn’t waste class time teaching us how to code what he’s talking about. I found that to be a great approach. Clearly, it was. By the end of Grade 12, all of us were writing simple AI’s for a game called Connect 4 or Hex. After taking grade 11 and grade 12, I feel that I’ve learned quite a lot about computer science, and that is shown by my good performance on programming contests.
    To compare, I sometimes go into the grade 10 class that is being taught by a teacher who has very little experience in problem solving and algorithms. All I ever see the grade 10 class doing is writing programs to display some sort of text on the screen. Here is the typical class assignment (Imagine it in a horrible chinese accent): “Ok… class… So, today you’re going to be making a program to read in the name of several items that can be sold in a shop. Each item will be assigned a price and a quantity. Your output will be the total price.” Perhaps, when you’re in the first month of Computer Science and you’re just learning basic syntax, that would be a good assignment. However, if you spend an entire semester doing assignments similar to that, you will never want to take Computer Science again. I feel that my school’s grade 10 computer science course discourages people to continue with the grade 11 and grade 12 courses. That is a great loss, because people who would potentially grow up to become great Computer Scientist go on to do something else.

    KL

    Reply to comment

  5. Posted by M Easter | May 13, 2007, 1:06 pm

    I completely agree that there is an artistic side to computer science. In fact, this very thought is a major theme to my blog.

    However, I think that music provides a much better analogy than poetry or English lit.

    Music, particularly classical music has these ideas:

    – a culture of architecture and patterns
    – a strong sense of “creativity within certain rules” combined with a rare, breath-taking applications of “breaking the rules” for certain effect
    – a long history of master composers and apprentices learning from the masters
    – many large-scale undertakings (e.g. symphony) where there are many layers and a lot of things going on at one time, which if not handled correctly, can be chaos

    As I write this, my inner voice is reminding me that poetry has similar ideas. But somehow, music seems like a stronger metaphor. Perhaps it comes from pair-programming: one can _see_ 2 people sitting at a piano, working out ideas, creating etc. I don’t get that sense with respect to writing.

    Reply to comment

  6. Posted by Woofster | May 13, 2007, 7:15 pm

    The “code is poetry” metaphor is common enough and tempting to boot, but it’s not really apt. The classical music metaphor isn’t much of an improvement. All of the points listed by M Easter are, point for point, applicable to literature and poetry.

    The temptation lies with the knowledge that coding — past a certain point of complexity, and given certain problem domains — frequently involves a considerable amount of creativity on the part of the coder. In my experience, however, a great deal of that creativity given even typically complex problem domains involves a filling in for inexperience which, in the long run, is merely a reinventing of the wheel. In a perfect world, in fact, free-wheeling creativity is not really what we want from programmers. What we want is programs which work, reliably and bug-free. Creativity may be called for in the inteface, or in optimization of operations, data storage, etc. But we don’t want engineers to be poets, not really. We want them to be smart, certainly, and able to translate demanding requirements into a semblance of simplicity — but poets?

    The best, most successful poetry frequently relies on ambiguity and irresolvability. Very often the most profound poems point to tensions in the human experience — a way of looking at the world which teaches us about ourselves and which instructs in recreating the “feeling of the feeling” of a certain emotional experience. It is true that rigorous analysis is called for in English classes, but the character of this analysis is never pointing towards coming up with a provable solution to a literary problem.

    As a coder I do understand what this post is trying to say, because I’ve had, many times, to employ creativity in solving problems. But in the end I think that this is fundamentally a mathematical exercise. There’s really no getting around the fact that coding is applied math. Not as much fun as a metaphor, but perhaps more apt in looking at the real problem of students not understanding basic concepts (and also more apt in understanding why coding may “feel” more like music, which has many mathematical facets).

    Just my .02.

    Reply to comment

  7. Posted by Konstantin Lopyrev | May 14, 2007, 1:24 am

    Hey, music and math used to be studied as a double major!

    KL

    Reply to comment

  8. Posted by Katie | May 15, 2007, 11:55 am

    You might be interested in Richard Gabriel. He advocates bringing writing workshop techniques into coding. His website is here: http://www.dreamsongs.com/.

    Reply to comment

  9. Posted by Justin Belanger | May 17, 2007, 7:52 pm

    Being a computer science student (in Grade 11, no less) myself, I have to admit that your article really made me think. After reading it, I questioned, “do I really know anything about programming?” Through all the lectures, the assignments, the work, I thought I had become adept in programming. As it turns out, I was wrong. I still do not understand the concepts of the language (Turing) that I’ve been learning, though I’ve gained the questionably useful ability to recite snippets of memorized patterns of code fairly easily. The worst part of it is that I really do enjoy programming. I find it highly rewarding, entertaining, and challenging, but having taken myself outside the “comfort zone”, I’ve realized that I don’t know the first thing about WHY I program the things I do. And, unfortunately, that’s sucked a lot of the enjoyment and meaning out of programming for me.

    Reply to comment

  10. Posted by M Easter | May 17, 2007, 10:11 pm

    I disagree with Woofster.

    I’m not sure that we want engineers to be poets, but we do want them to be composers. To know that there are a variety of compositional tools at their disposal, and there is a standard approach of knowing when to use them.

    It may well be a romantic whimsy, but I see the works by Knuth, a great algorithm book like CLR, etc as being on par with the scores of Beethoven, Mozart, Bach. They should be studied with a view to that sense of virtuosity. Also, E Raymond’s book on the philosophy of Unix is a great “computational appreciation”.

    It is true that often engineers are stuck in rather routine situations. In the musical analogy, we are writing jingles for commercials and can’t really take chances with creativity. A jingle for McD’s that starts with a weird Chopin chord change isn’t going to fly. Neither will a payroll system that is based entirely on Ruby closures.

    But the awareness of where we are on the spectrum, and the sense of wonder for “the greats” is of tremendous value.

    What’s more, it could energize young students. I’m not sure that “don’t kid yourself: coding is applied math” is exactly the message we want to send. At the very least we could say:

    “coding is a working with a particular instance of a Turing machine, which is very much _pure_ math. Speaking of Turing, let me tell you about this fantastic computational composer……”

    Reply to comment

  11. Posted by Tony | May 19, 2007, 11:34 pm

    thx Katie – I’ll check out Richard’s website :)

    Justin – thank you for sharing! Your situation is quite representative of a promising computer science student, held back by the flaws of the educational system. Just take control, push your own boundaries and hold on – it gets better ;)

    @M Easter, Woofster – alright, so creativity is not desired in routine, code-monkey tasks. Though Engineers and Computer Scientists don’t want to code monkey around either. Creativity is essential to solving new problems and pushing the boundaries of existing technology.

    So yes – programming _is_ applied math. The said math can also be applied in new, creative ways for fun and profit.

    Reply to comment

Post a comment

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>