# Kim Davis▸ U4: Math Connections

In the Prep and Junior classes I would scaffold and build on skills in Math.
First I would start the children with drawing and discussing Math problems e.g. in addition and subtraction using the SHOW AND TELL APP , as per this example https://youtu.be/qE94GppdKvI
Next I would use Scratch Junior, as per this example to model to children how to complete and make this simple game . They could start versions of their own, incorporating the Math. See eg https://youtu.be/GuJZxNVS5HA
Finally I would move to Scratch for students to complete a SCRATCH MATHS CHALLENGE . Then we would unpick it and have a go at creating our own. As I did this one I got a little stuck towards the end. Had to debug and problem solve. I learnt that it's not only about making the game (which I was so determined to do) but in the revision and editing. I have written the steps for beginners to use:

USING SCRATCH TO CREATE A SIMPLE MATHS QUIZ
1 Delete the sprite and choose a character
2 Choose a new sprite which will be the Game Show host
3 Choose a new background – for a game show
4 Need to programme the Game Show host to start asking questions
5 You will be programming the Sprite, not the stage so click on the sprite
6 Select scripts tab to start building the scripts
7 Go to Events blocks (brown)
8 Drag first one , when green flag clicked
9 Here you want the host to welcome the player to the game
10 Go to Looks block (purple), drag a Say block tap into text box, delete the text , type text into white part e.g Hello and welcome to my game show. Are you ready?
11 Need to change the number of seconds because it is a long sentence. Change number to slightly bigger value e.g. 7
12 Click on the green flag to test
13 Need to add more blocks of code so the host can ask more questions
14 Go to Sensing blocks (blue). Find block that says “Ask what is your name?”
15 Click on it, drag onto my blocks and delete the default text
16 What is 5 + 5 ? This will also bring in a block that helps the player to write in an answer. Need to add more code to this part
17 Need to use some selection here. If the player puts in one answer something will happen or alternative answer, something else will happen
18 First code for if the player types in the correct answer e.g. if the player says 10, the host will say Good job
19 Next if the player types in the wrong answer e.g. if the player says 5 the host will say No that’s not right. Please try again.
20 Go to Controls Blocks(yellow) and drag the If and else block
21 Need to add text into the If part e.g. if the answer is 10 I want the host to say Good job
22 Go to Sensing blocks (blue) drag answer block
23 Go to Operator blocks (green) drag block with = in the middle
24 Drag answer block into first part and 10 into the second part, then drag this blu block into the yellow If block
25 This means that if the player types in 10 something is going to happen e.g. the host will say Yes good job
26 Go to Looks block (purple), drag a Say block tap into text box, delete the text , type text into white part e.g Yes good job that is correct, change seconds 6
27 Go to Sound block (pink), drag play sound scroll down under pop and record saying Yes good job that is correct
28 Click on the green flag to test
29 Need to type text into Controls Blocks(yellow) Else Block – incase player types in a different answer. The host will say No that’s not right. Please try again.
30 Add another Looks block (purple), drag a Say block tap into text box, delete the text , type No that’s not right. Please try again. Change seconds to 6
31 Click on the green flag to test
32 Now the questions are set up. We we can keep repeating this block of code for the rest of the game to ask any question
33 To add something new, go to Data, click Variables, score. You need to make a Variable type in score (you could also have Level, Timer etc)
34 Slide this block at beginning before “When the green flag is clicked” (the score will start at 0)
35 Now when the host asks a question and the player answers correctly the host will say Good Job and the score will increase by 1 each time
36 Need to drag in change score ( to get 1 point) and drag it under Yes good job that is correct
37 Click on the green flag to test
38 Need to adjust this if the player types in the wrong answer also
39 Need to drag in change score ( to lose 1 point make it -1 ) and drag it under No that’s not right. Please try again.
40 Click on the green flag to test
41 Need to continue this pattern now by continuing this block of code. Can right click to duplicate. It copies that whole section of code
42 Change text to type in next question (s)
43 Can add in some more variables here. Go to Data, click Variables, score. You need to make a Variable type in score (you could also have Level, Timer etc)
44 Can programme to change backgrounds each the player gives a correct answer
45 Import the number of backgrounds to match the number of questions I have
46 Click on stage and import backgrounds to match number of questions
49 Go to Events Blocks(brown) When the green flag is clicked, then Looks (purple) – it switches to the background
50 Type in the first background e.g.type bedroom into the Looks
51 To change the backgrounds each time an answer is correct, go to Events Blocks(brown), drag When I receive
52 Add flower bed & all of the other backgrounds
53 Click out of Background into the host Sprite
54 Go back to script go to Events (brown), add a Broadcast block
54 Drag it under the change block because that is where the background should change, each time the player gets the answer right
55 So you have a set of code for the Sprite (the host) and a set of code for all of the Backgrounds
56 Click on the green flag to test
57 The player needs to know the quiz is finished. Add final blocks of code to show this
58 Go to Looks block (purple), drag a Say block, type a message to say the game is finished