0% found this document useful (0 votes)
30 views7 pages

Coding Projects: TPT Students Learn To Code

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
30 views7 pages

Coding Projects: TPT Students Learn To Code

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

Coding Projects

Grade 5 Math
Ontario Curriculum
Lesson 1

TpT Students Learn To Code

1
Let’s Code! Notes for Teachers
This package of Grade 5 Mathematics Coding lessons have been designed to meet the
Grade 5 Ontario Math Curriculum Coding Expectations:

C3.1 Solve problems and create computational representations of mathematical situations by


writing and executing code, including code that involves conditional statements and other
control structures.

C3.2 Read and alter existing code, including code that involves conditional statements and
other control structures, and describe how changes to the code affect the outcomes.

Students will be using Scratch, a free block coding program from educators at MIT. Scratch has
been designed to help students develop a strong foundation in coding. www.scratch.mit.edu

*Each lesson links to a short video tutorial teaching your students the coding concepts
required to complete each project.

Students are encouraged to apply the coding skills learned in the videos in new and creative
ways to enhance and individualize their math projects.

Terms of Use: The following project is for you to use with your students. If you have questions,
please feel free to send me a message through TpT Students Learn to Code:
https://www.teacherspayteachers.com/Store/Students-Learn-To-Code

Use and make copies for personal classroom use by a single teacher.

Please DO NOT
• Share with colleagues without purchasing additional licenses. If they like the product please
send them to my TpT store.
• Sell or distribute this product or any part of this product or place it on the Internet.
• Claim this work as your own, alter the files in any way, or remove or attempt to remove the
copyrights/watermarks.
• It is a violation for individuals, schools, and districts to redistribute, edit, sell, or post this item
on the Internet or provide it to others . Disregarding this copyright is strictly forbidden and a
violation of the Digital Millennium Copyright Act (DMCA).

2
Students Learn to Code

For many, the idea of teaching students how to code can be a little
frightening. Not to worry. When taught effectively, coding is quite simple
and students enjoy it a lot!

Coding games will engage students and unleash their creativity while
meeting and exceeding the Ontario Mathematics curriculum coding
expectations.

The Grade 5 Ontario Math Coding Expectations revolve around two basic
concepts: conditional statements and other control structures.

Conditional Statements

As presented in the Ontario Math Coding Curriculum, conditional


statements are coding instructions, “Used to compare values and make
decisions. A conditional statement tells a program to execute an action
depending on whether a condition is true or false. It is often represented as
an if-then or if-then-else statement.”

For example, in Galactic Ghost,


Gr 5 Lesson 1, this if-then statement
tells the program to stop the game
when the health of the Ghost =0.

3
Control Structures
As presented in the Ontario Math Coding Curriculum, control structures
are, “A line or block of code that influences the order in which other code is
executed. Control structures affect the flow of the program and include
sequencing lines of code, repeating lines of code (loops), or selection to
execute or not execute specific lines of code (conditional statements).
Sequence, repetition, and selection are all control structures.”

For example, in Lightning Run,


Grade 5 Lesson 2, this code includes
sequential code, an if/then statement,
and a repeating forever loop.
Notice that the if/then statement
is nested inside a forever loop.
Finally, this piece of code is operating
concurrently with other coding blocks.

Efficient Coding
Compared to the code on the right, the code on the left is much easier
to write and a more efficient way of achieving the same results.
The code on the left is an
example of efficient coding
(far fewer coding blocks).

4
Additional Learning

Using conditional statements, control structures and a combination of


sequential, concurrent, repeating and nested events makes for a lot of
fun when coding with Scratch. The games and activities presented in this
grade 5 package will be engaging for all students while allowing for
exploration and mastery of conditional statements, control structures,
sequential, concurrent, repeating and nested events.

Grade 5 students that are new to coding may benefit from working through
an introduction to coding as presented in the Grade 4 coding unit here:
https://www.teacherspayteachers.com/Product/Lets-Code-Grade-4-Ontario-
Math-Complete-Set-9133146

The Grade 4 Mathematics Coding unit focuses on the concepts of


sequential, concurrent, repeating and nested events. With this
understanding, students can work confidently through the Grade 5
mathematics coding unit.

5
Let’s Code! Grade 5 Math
Student Activity Card Lesson #1

Student Coding Task: Create a game called Galactic Ghost!


YouTube @ Pekka Reinio Video tutorial: https://youtu.be/-CixIEXof24

Go to Scratch: www.scratch.mit.edu and click Create.


Get a space background and a ghost sprite.
Code the Ghost to move up, down, left and right using the arrow keys.
Create a variable called Lives which starts at 10 when the game begins.
Code a Pufferfish (Space Worm) to move around the screen forever.
Next Level Coding:
If the Space Worm hits the Ghost, you lose a point (Lives) and the Space Worm
goes to a random position.
Duplicate the Space Worms two times.
Beast Mode Coding:
When points = 0, the game ends, everything stops.
Add a title, sound effects and music.

6
Let’s Code! Grade 5 Math
Teacher Rubric Lesson #1

Coding Lessons #1-4 Grade 5 Ontario Math Curriculum: Conditional Statements


If/then statements,If/else statements. Control Structures - sequential, concurrent, repeating
events, nested events, variables (Points/Lives/Health).

Success Criteria:
Level B
Student has a space background and a ghost sprite.
The Ghost moves up, down, left and right using the arrow keys.
A variable called Lives starts at 10 when the game begins.
A Space Worm moves around the screen forever.

Level A
If the Space Worm hits the Ghost, a Life is lost and the Space Worm goes to a
random position.
There are now 3 Space Worms moving around the screen.

Level A+
When points = 0, the game ends and everything stops.
Student has a title, sound effects and music.

You might also like