Teaching Algorithms Without The Computer

algorithms.jpg

Introduction

Yes, you read the heading correctly. No, I didn't mess up. Teaching algorithms without a computer is actually a thing, and while it might seem a little counter intuitive, it can bring about some outstanding learning opportunities. Computational Thinking is a big teaching point in Digital Technologies classrooms. If you're new to this concept, essentially, it is an higher order thinking skill that helps students to find logical methodologies to break down problems into smaller tasks before stepping through a process that enables them to construct meaningful algorithms.

There are four stages (sometimes referred to as pillars) of computational thinking. Each builds upon the previous one, in an attempt to help students create logical and efficient computational processes. The steps taken are:

  1. Decomposition - is the process of taking a large problem and breaking it down into smaller, more manageable ones. The idea here, is that students can find meaning in simplicity. Making a task easier should, theoretically, increase the understanding of what is being asked, and therefore, make the outcome better.
  2. Pattern Recognition - is where patterns are investigated and identified. During this stage, repetitive events are highlighted and listed.
  3. Abstraction - is the process of looking at the identified list of patterns determining what information we need, and what information we don't need. This step could probably be called variable identification as well.
  4. Algorithm Building - this final step involves building algorithms from the information produced in the previous steps. It can be represented, initially, as a flowchart, or pseudocode, before being written using the programming language being taught.

It is this process, that I oftentimes, find a little easier to teach in an 'unplugged' way. Initially, I find students don't like it. They, after all, choose Digital Technologies because they believe being a student in this class will automatically grant them unrestricted access to their laptop, however, they quickly discover that the privileges they thought they were heaping upon themselves, soon dry up like a leaf in an Autumn breeze.

Disconnect Your Connection

disconnect.jpg

This is not as difficult as it might initially sound. I just tend to make sure that in a 'disconnected' lesson, I have pens/pencils and paper available for the inevitable, 'Sir, I don't have any books with me.'

You can be guaranteed, that at least one person in the class will try this out - the forgetting, or not having books or writing implements. They seem to think that they're the only one who finds this gag original, despite the person next to them having used it the last time I took them out of their comfort zone and removed digital devices.

Anyway, a class set of writing tools and paper is a must.

The next item I have is essentially the only other item you're likely to need for this activity. And this is a few different cake recipes. Now, generally, I print these off (enough for one per person), however, if you're more paper conscious than I am, you could just as easily display it over a projector as well. Each handout has three different recipes on it. This is for two reasons: 1) because it is a good way to highlight pattern recognition, and 2) I don't generally use this as a collaborative task, and like to have multiple recipes to assign the students. In this manner, in any given size class, only a third of the class will ever have the same recipe. (I really think this is a concept that every student in my Digital Technology classes needs to understand, and unfortunately, no matter how well meaning the students are, in a group, someone is almost always going to take a backseat, and miss out on important concepts.)

So, give out the recipes, and watch them look at you like you've lost your mind. Firstly, for having the audacity to suggest that they, the Digital Technology students, will not be needing their laptops for this activity, and secondly, for giving them cake recipes. Some of the reactions I've had over the years have been great - I often think that I should have been recording these comments somewhere so that when I retire, I can write a book on them. But, that's beside the point.

With the recipes distributed, I begin to explain my theories behind how studying these can lead to a better understanding of algorithm development. I try and articulate, as best I can, that a recipe (pretty much any procedural task) and an algorithm are quite nearly one and the same. This sometimes takes some careful rewording before every student in the class can see what I'm saying, but generally speaking, the success rate is well into the ninetieth percentile.

I think that this part of the activity requires them to see past the recipe as being a recipe for a cake and really considering how it can become a program used be a computer to achieve something. I use recipe analogies a lot in my teaching, not because I'm a food junkie, but because they seem to offer great parallels in technology-based subjects.

As students progress through the earlier parts of this activity, we explore, together, some of the computational thinking skills that I'm hoping this activity will consolidate. I'll raise questions to prompt their thinking and to hopefully help them navigate the task in the right direction.

Questions I've used at various times can include some or all of the following:

  • How is the recipe broken down?
  • How can it be broken down even further?
  • Are there any patterns that can be easily (or not easily) seen?
  • What information in the recipe is essential, and what information is not essential?
  • How many variables would be needed in this algorithm?
  • How would you write this as a computer program?

Finding Solutions To Problems

solution.jpg

The problem that students are presented with it to build an algorithm from a recipe. Not a difficult task, but often challenging. Which, is is good thing. If we were never challenged, then we wouldn't be experiencing growth, would we?

After dividing the recipes among students, the processes they use vary significantly, despite the fact that computational thinking really only has four steps, each of which tends to build from the previous one making it a quite linear-type process. I don't mind so much, the different paths they take, providing that they can accomplish what they set out to do, which is to turn the recipe into an algorithm that could (theoretically) be used in an application.

What's also exciting is that as they work their way through this, they come to the realisation that they wouldn't be able to complete any real program without writing further algorithms. For example, I had a student, previously, who was writing their algorithm, and they were making up different function names. One name they came up with was: mixCake(). I happened to be watching them as they were pondering this, and then, finally, they asked me where they would get the mixCake() function from. I smiled and just stared at them. They stared back, and slowly, their eyes widened slightly.

The penny had dropped.

'You mean I'd have to write this one too?' they exclaimed.

I smiled some more before answering. I was savouring the moment. There is a great deal of satisfaction when a student gains deep understanding from an activity they are working on. 'Yep. You'd need to write all of them!'

They'd discovered for themselves, that so often, in solving one problem, many more can be created, and that we just need to be persistent in chipping away until we have created a more robust solution.

Conclusion

As I bring this in for a landing, I find this to be a great activity for fleshing out and consolidating computational thinking, and to get students to think about how pretty much any everyday task can be converted into an algorithm. I find they don't really think in this manner, until it has been highlighted to them, and I guess, why would they. We're not wired to look at the world around us and see if we can fit it into an application. It takes practice.

And sometimes, as you have just read, there are moments when students discover more than you had intended, and that is also fantastic.

It's great, also, for getting them off their computers and realising that not all app development is done in front of a screen. All too often, they seem to think that for something to be good, it must be created in a digital manner. While I do love creating with a computer, I'm old enough to know that disconnecting for a time is also valuable.

I hope that you have found this interesting, and that you have perhaps found something that you can take with you and use in the classroom, if you haven't already been doing something similar. I don't expect the idea of using a cake recipe is a new way of teaching algorithm development, so if you have been using this, or something similar I'd love to hear your thoughts and experiences.


Sources

Kelly Sikkema - title image background
Jonathan Kemper - disconnect image background
Neil Thomas - solution image background

This post is an elaboration on an idea I generated in a previous post titled Coding In Schools

H2
H3
H4
3 columns
2 columns
1 column
2 Comments
Ecency