I am at the third hour of the “20 Hours of Code” and the topic is Computational Thinking.
Computational Thinking is the 4 stages of problem-solving in computer sciences:
- Decomposition: Analyze the problem and break it up into smaller problems
- Pattern Location: See patterns that are common in all the problems
- Abstraction: See what is different between all the problems. Take out all differences in problems so we are left with a common framework, model etc. that will work for all the problems
- Algorithms: Write out a sequence of instructions using the common abstraction allowing for one variable to make differences
I am not a computer science person, so this is the best I can do explaining what these 4 stages are. I hope I got it right!
The problem we had to solve for Stage 3 is whether we can write a set of instructions for a computer in order to draw a monster’s head.
Draw a Monster’s Head
- Decomposition: We have monsters which are only heads with different parts. How can we make a set of instructions so that another student can draw the same head without seeing the original?
2. Pattern Location: We can see that all monsters have a head, eyes, ears, nose, mouth
3. Abstraction: This is the sentence that will work for all monsters.
- Draw a _______head
- Draw a _______ eyes
- Draw a _______ears
- Draw a _______nose
- Draw a _______mouth
4. Algorithm: These are the instructions using the abstraction adding in one variable.
How did we do?
The original intention is on the left. The end result of the instructions is on the right. It was not perfect. The mark on the head is different. The mouth turned out different. The activity appears to be quite easy but we ran into glitches when:
- We didn’t draw our original as intended
- We gave the wrong algorithm
- (We even followed the algorithm incorrectly though we discussed this as something a robot or computer would NOT do. “This is why we depend on robots, computers. They can automate tasks perfectly without getting tired or making mistakes.”)
The learning came when we went wrong and had to figure out where we went wrong. We even discussed the differences between humans following instructions and robots/computers following instructions.
One of the take-home messages is that we have to be careful in our design and programming or we’re not going to end up with what we intended.
My kids have skipped ahead to Stage 5 or 7 (to the computer activities, of course!) where they are programming in more complexity. The problems are called “The Artist” and the children have to instruct the artist to draw certain shapes:
I find the paper and pencil activities easy for me to understand. The children zip through them and can’t wait to get to the computer activities. I’m looking at “The Artist” and anticipating that it’s going to be challenging for me to go through them.
This is a long way from my teacher education studies when I was instructing the turtle to draw a green square using LOGO. 🙂