Block based programming Lesson 1

Do Now
Write a sequence of instructions
so the bird reaches the pig. 
For example move forward two times. 
1 / 22
suivant
Slide 1: Question ouverte
ComputingLower Secondary (Key Stage 3)

Cette leçon contient 22 diapositives, avec quiz interactifs et diapositives de texte.

time-iconLa durée de la leçon est: 50 min

Éléments de cette leçon

Do Now
Write a sequence of instructions
so the bird reaches the pig. 
For example move forward two times. 

Slide 1 - Question ouverte

Cet élément n'a pas d'instructions

Block based programming
Lesson 1

Slide 2 - Diapositive

Cet élément n'a pas d'instructions

Lesson objectives 
Conquer: Understand the key programming concept of sequencing.
Aspire:Apply sequencing to solve programming problems.

Slide 3 - Diapositive

Cet élément n'a pas d'instructions

What is programming?
“Programming is how you get computers to solve problems”

  • Programming is the process of creating a set of instructions that tell a computer how to perform a task.

  • We have 2 main kinds of programming:

Slide 4 - Diapositive

Cet élément n'a pas d'instructions

Creating a sequence 
A Sequence, is the order that commands are executed by a computer, this allows us to carry out tasks that have multiple steps.

  • You are going to create a sequence of instructions

  • Create a set of instructions to make a cup of tea.


Slide 5 - Diapositive

Running code in order

Line 1 will run first 
then line 2
then line 3

The instructions have to be written in the right order. 
Create a set of instructions to make a cup of tea.

Slide 6 - Question ouverte

Be super picky with students instructions/answers.

Examples 
"Put water in the kettle" where from?
"stir the tea" With what? 

Make sure students are really specific with their instructions as in programs you have to be really specific. 
My method 
  1. Fill the kettle​
  2. Boil the water​
  3. Add tea bag to mug​
  4. Pour boiling water into mug​
  5. Wait​
  6. Remove the teabag​
  7. Add sugar (if wanted)
  8. Add milk (if wanted)

Slide 7 - Diapositive

Be super picky with students instructions.
Examples
"Put water in the kettle" where from?
"stir the tea" With what?
Make sure students are really specific with their instructions as in programs you have to be really specific. 

This example is not perfect, no specific enough. 
What is sequencing?
A
A set of instructions
B
A set of instructions in order.
C
A program created by code.
D
The result of our program when run.

Slide 8 - Quiz

Cet élément n'a pas d'instructions

What is programming?
A
The order in which we write our code.
B
The programs we use.
C
A set of instructions to complete a task.
D
The result of our program when run.

Slide 9 - Quiz

Cet élément n'a pas d'instructions

Applying our skills 
We will now apply our new found skills in sequencing to create some programs. 




Slide 10 - Diapositive

Cet élément n'a pas d'instructions

Lets have a go at programming some sequences.
On the first level, we want the angry bird to reach his nemesis the pig.
 

We need to create a sequence of instructions that make this happen
Drag the move forward into the when run box. Then click run. 

Slide 11 - Diapositive

This is where you will demo the level, you could use student feedback to build it.

The next slide has a set of tasks for the student to complete. 
Have a go ISL. 
Complete the first 6 levels

Click here 

Slide 12 - Diapositive

When majority of student have reach level 6, move to next slide.
Making tea
So we have the written process we would follow to make 1 cup of tea.

  • If this was a program we have coded, and we wanted to create 5 cups of tea we would have to repeat the instructions 5 times.

Slide 13 - Diapositive

Cet élément n'a pas d'instructions

Our instructions would look like this

Slide 14 - Diapositive

Explain this would take ages to code, this is not an efficient way of writing instructions. 
For 25 cups of tea
This would take a really long time if we were writing this program, so we use a coding concept called iteration (loop).

Slide 15 - Diapositive

Cet élément n'a pas d'instructions

Using a Loop​
  • A loop in a computer program is set of instructions that are repeated until the loop meets a STOP condition.​

  • A STOP condition will tell the program when it’s completed.​


Slide 16 - Diapositive

Cet élément n'a pas d'instructions

So instead of 10 lines of code, we can do it in 2.

Slide 17 - Diapositive

Cet élément n'a pas d'instructions

Lets have a go at programming some sequences.
(ISL)
We will now use loops to help the angry bird reach the Pig. 
Try to complete them with as few blocks as possible. 
Limited blocks

Slide 18 - Diapositive

3 quick exit ticket questions

With a just in case mastery task for typing
What is sequencing?
A
A set of instructions
B
A set of instructions in order.
C
A program created by code.
D
The result of our program when run.

Slide 19 - Quiz

Cet élément n'a pas d'instructions

What is a loop?
A
A set of instructions to complete a task.
B
A set of instructions in order.
C
A repeated section of code
D
The end result of your program.

Slide 20 - Quiz

Cet élément n'a pas d'instructions

What is programming?
A
The order in which we write our code.
B
The programs we use.
C
A set of instructions to complete a task.
D
The result of our program when run.

Slide 21 - Quiz

Cet élément n'a pas d'instructions

Mastery task
Continue to practice your mastery of different typing skills.

Start on either beginner or intermediate.

Slide 22 - Diapositive

Cet élément n'a pas d'instructions