Minds On
The atmosphere

Brainstorm
Brainstorm
Let’s brainstorm images, words, or ideas that come to mind when you think about greenhouse gases and climate change.
Complete the Greenhouse Gases and Climate Change T-Chart in your notebook or using the following fillable and printable document. If you would like, you can use speech-to-text or audio recording tools to record your thoughts.
Greenhouse gases |
Climate change |
---|---|
Press the ‘Activity’ button to access Greenhouse Gases and Climate Change T-Chart.
What do you wonder?
What are some unanswered questions or things you wonder about regarding greenhouse gases and climate change?
Record your ideas in a notebook or another method of your choice.
Action
Greenhouse gases
The greenhouse gas effect works…like a greenhouse!
Gases in the atmosphere, such as carbon dioxide, trap heat (similar to the glass roof of a greenhouse), and these gases are called greenhouse gases.
These greenhouse gases that are released into the Earth’s atmosphere are increasing the Earth’s temperature.
The greenhouse gas effect
An illustration of the greenhouse gas effect. The sun radiates its energy on the Earth. This energy can be reflected back into space, absorbed at the surface of the Earth and/or trapped by greenhouse gases in the atmosphere. Greenhouse gases such as carbon dioxide, CFCs, haloalkane, methane and nitrous oxides are both produced in the natural environment and through human activity. The additional greenhouse gas production due to human activity has led to an increase in temperature as more of the sun’s energy is trapped in the atmosphere.
UN Sustainable Development Goals

The United Nations (UN) is a group of many countries from all over the world that have come together to create a better future for people and the environment. Together, they have created 17 goals.
Goal #11 is called Sustainable Cities and Communities. This means that our cities and communities should be inclusive, safe, resilient, and sustainable. Communities that are not sustainable can lead to pollution, unrest, insecurity, lack of economic growth, and more.
Mitigation
In this learning activity, we will be focusing on mitigation, and considering how communities can lessen the impacts of global warming, and contribute to making themselves more sustainable.
Mitigation aims to reduce the causes of climate change by supporting strategies that absorb or eliminate greenhouse gases.
Some examples of mitigation are:
- limiting deforestation
- creating new forests by planting trees
- improving energy efficiency in all economic sectors
Did You Know?
Did you know?
Deforestation is the destruction of the world’s forests — mainly rainforests — either through direct human activities and removal, like logging and clearing for agriculture and grazing, or as the indirect effects of pollution, climate change, and acid rain.

Deforestation
Let’s code!
Coding is a computer programming language that can be used to model concepts and design programs.
Scratch is a coding application that uses blocks to create code. Let’s learn more about how we might use Scratch.
Student Success
Let's think about code!
When you start your own project in Scratch, you will be making code using blocks. A block is a small piece of code that appears to be a puzzle piece or a building block. You can use blocks to build your own code. Each kind of block controls an action. There are 9 kinds of blocks available at the start! As you learn more, you may find other types of blocks to add to your code.
Each block describes an action that is performed by a character. An action is like an instruction. A character can be a sprite or a backdrop. A sprite is an image of a person or object. A backdrop is an image of a background or a place. Your code creates actions that affect a sprite or a backdrop. You can choose if you are using a sprite or a backdrop.
As you make your code, you are connecting blocks to make a code block. Your block of code is known as a code block or a script! The space where you build your code is also known as the scripts area. Press and place each of your blocks into the centre area to make your code. When you activate your code, it is known as running your code.
To start creating code, press on a block and move it to the center area. Press and snap or place your next block under your current block. Now you have created a code block!
Once you have made a code block, your code should perform an action. The action can be made by a character like a sprite or a backdrop. You can make as many characters as you like. You can make different coding instructions for each one!
You can change the order of your blocks or delete a block at any time. You can also copy or duplicate a section of your code. To copy code, right-click on the first block you want to copy. It will copy all of the blocks that follow it. Connect your copied code to the bottom of the code block you want to it added to!
Note to teachers: See your teacher guide for collaboration tools, ideas and suggestions.
To explore some possible code elements and blocks that you may come across in this learning activity, press on the following tabs:
A sprite is a character that carries out the actions that you make with your code.

The backdrops can also be changed by your code. Some blocks change what the backdrop will do!

A motion block makes a sprite move! You can move, turn or ask a sprite to move to a certain position.

A looks block changes how a sprite looks! You can choose costumes for each of your sprites.

A sound block make audio, or a sound. You can use the audio that is included in Scratch. You can also record your own sounds!

An events block is the start button for a code block. To decide when you want your code to run or start, place an events block at the beginning of your code. Your events block is how you decide when your code will start!
Your events block has to be your first block because it starts your code. You can choose how you want your code to start!

A control block is a block that controls when an action happens. A control block can change the order and timing of an action. You can use control blocks to wait, to repeat and even to loop your code!

A sensing block is a block that helps characters work with each other.
For example, what happens if you have two sprites ask each other a question?

An operators block is a block that adds math to your code.
Operators blocks can be tricky to put together.
Before you can put an operators block in your code block, you have to add another block! You could use a sensing block or a variables block. You will need to fill any blank spaces that are part of your operators block. Press and drag a sensing or variables block to snap into any blank spaces. Now you can put your operator block in your code block!

A variables block is a block that keep track of information. A variables block helps to change how to code is run each time. It can be used to create a challenge in a game!

My Blocks is a special area to keep your very own blocks! You can save your own blocks in the My Blocks category.

Now you have explored what kind of blocks you can use in Scratch!

In this coding activity, you will explore the relationship between creating new forests and reducing greenhouse gases.
Your task is to code or remix a simulation that shows how planting trees can help to reduce the overall amount of carbon dioxide in the atmosphere.
The game will be designed in such a way that every time the player plants a new tree, the relative amount of carbon dioxide ppm (parts per million) in the atmosphere is reduced.
400 ppm is widely regarded by climate scientists as a dangerous amount to have in the atmosphere, so the player will have to plant enough trees to help it reach a safer amount – 350 ppm.
You will access two options for this section. You may choose to explore one or both options:
- Option A: Remix the completed application and answer related questions as you “play with the code.”
- Option B: Create the entire Scratch application by following the guided steps.
Option A
For this option, we will remix and alter the code in Scratch.
Access the following completed Scratch code: Scratch(Opens in a new window)

When the green flag is clicked, many different CO2 sprites will travel across the screen as if moving through the atmosphere, while the tree moves in and out as if it is breathing.
This is a screenshot of the Scratch code for the Carbon Dioxide sprite. On the right, there is an image of the stage. There is a leafy tree standing on a backdrop that includes grass and sky. In the top left corner, there is a counter that indicates how much carbon dioxide is in the atmosphere. It reads: ppm of CO2: 400. Underneath the stage, the Carbon Dioxide sprite is highlighted. The Carbon Dioxide sprite is an oval shape made of three smaller spheres that fit together. There is a gray sphere in the center and two red spheres on either side, representing the two atoms of oxygen that are bonded to one atom of carbon, which make Carbon Dioxide. On the left, there are three different Scratch code scripts. One of the scripts includes a question written on a post-it note for the learner to answer about the code. The code scripts are: When green flag clicked, go to x: -188 y: 117, repeat until CO2 is less than 350, create clone of myself, (create clone of myself is within the repeat until block), forever, the following blocks are within the forever block, wait until ppm of CO2 is less than 350, hide. When I start as a clone, set size to 100%, show, go to random position, turn clockwise pick random –30 to 30 degrees, repeat 15, move 5 steps (move 5 steps is within repeat block), delete this clone. The question attached is: How are the Carbon Dioxide clones animated in the code? When I receive fix carbon, delete this clone.
Task 1
- Press the GREEN FLAG to execute the code. Play the game a few times to understand the code.
- Press the TREE SPRITE and respond the following questions about the code:
Complete the Option A Activity: Task 1 in your notebook or using the following fillable and printable document. If you would like, you can use speech-to-text or audio recording tools to record your thoughts.
Questions |
Your responses |
---|---|
At what value does the carbon dioxide level start? |
|
Alter the initial value of the ppm of CO2 variable to start at 500. How does this impact the game? |
|
By how much does the carbon dioxide level in the atmosphere decrease each time a tree is planted? |
|
Alter the value by which the ppm of CO2 variable decreases each time a tree is planted to a -10 integer. How does this impact the game? |
|
At what value does the carbon dioxide level get to in order for the game to end? |
|
Alter the value of carbon dioxide at which the game ends to a lower number. How does this impact the game? |
|
Record an equation for the original code to represent the starting amount of carbon dioxide in the atmosphere and the decreasing amount over time. Use n to represent the number of trees and T for total amount of carbon dioxide in the atmosphere. |
|
How many trees does the player need to plant in order to reduce the carbon dioxide level to 350 and end the game? Check your answer by pressing on the Trees sprite in the game with the original link, and counting how many times you must press in order for the game to end. |
Press the ‘Activity’ button to access Option A Activity: Task 1.
Press ‘Let’s Check!’ to access the correct responses for Option A.
Questions |
Your responses |
---|---|
At what value does the carbon dioxide level start? |
The carbon dioxide level starts at 400. When you press on the green flag, the ppm of CO₂ variable is initially set to 400. |
Alter the initial value of the ppm of CO₂ variable to start at 500. How does this impact the game? |
The player will need to plant more trees, since there is more carbon dioxide in the atmosphere to start. |
By how much does the carbon dioxide level in the atmosphere decrease each time a tree is planted? |
The ppm of CO₂ variable is decreased by 5 each time the player presses on a tree. We know this because it currently displays -5 in the change ppm of CO₂ block. |
Alter the value by which the ppm of CO₂ variable decreases each time a tree is planted to a -10 integer. How does this impact the game? |
The player does not need to plant as many trees, or press on the Trees sprite as many times, since it reduces the carbon dioxide in the atmosphere at a quicker rate. |
At what value does the carbon dioxide level get to in order for the game to end? |
Once the ppm of CO2 variable reaches 350, the game ending backdrop is displayed. This information can be discovered inside the forever block under the 'when this sprite clicked' block. |
Alter the value of carbon dioxide at which the game ends to a lower number. How does this impact the game? |
The game takes longer to end, since the player must press more times on the Trees sprite to reduce the carbon dioxide in the atmosphere to the lower value. If this value is not a multiple of 5, then the equal sign comparison operator would need to be changed to a less than sign. |
Record an equation for the original code to represent the starting amount of carbon dioxide in the atmosphere and the decreasing amount over time. Use n to represent the number of trees and T for total amount of carbon dioxide in the atmosphere. |
T = 400 – 5n |
How many trees does the player need to plant in order to reduce the carbon dioxide level to 350 and end the game? Check your answer by pressing on the Trees sprite in the game with the original link, and counting how many times you must press in order for the game to end. |
Substitute 350 in for T – you should get 10 for n. |
Task 2
- Press on the CARBON DIOXIDE sprite so that the code is displayed. The carbon dioxide sprite clones are animated – they are moving across the screen.

This is a screenshot of the Scratch code for the Carbon Dioxide sprite. On the right, there is an image of the stage. There is a leafy tree standing on a backdrop that includes grass and sky. In the top left corner, there is a counter that indicates how much carbon dioxide is in the atmosphere. It reads: ppm of CO2: 400. Underneath the stage, the Carbon Dioxide sprite is highlighted. The Carbon Dioxide sprite is an oval shape made of three smaller spheres that fit together. There is a gray sphere in the center and two red spheres on either side, representing the two atoms of oxygen that are bonded to one atom of carbon, which make Carbon Dioxide. On the left, there are three different Scratch code scripts. One of the scripts includes a question written on a post-it note for the learner to answer about the code. The code scripts are: When green flag clicked, go to x: -188 y: 117, repeat until CO2 is less than 350, create clone of myself, (create clone of myself is within the repeat until block), forever, the following blocks are within the forever block, wait until ppm of CO2 is less than 350, hide. When I start as a clone, set size to 100%, show, go to random position, turn clockwise pick random –30 to 30 degrees, repeat 15, move 5 steps (move 5 steps is within repeat block), delete this clone. The question attached is: How are the Carbon Dioxide clones animated in the code? When I receive fix carbon, delete this clone. When the green flag is clicked, many different CO2 sprites will travel across the screen as if moving through the atmosphere, while the tree moves in and out as if it is breathing.
Complete the Option A Activity: Task 2 in your notebook or using the following fillable and printable document. If you would like, you can use speech-to-text or audio recording tools to record your thoughts.
Questions |
Your responses |
---|---|
Describe the movement of each Carbon Dioxide clone before they are removed from the stage. |
|
Alter the code to move the Carbon Dioxide clones more quickly across the stage. What did you change in the code? |
|
Alter the code to make some of the Carbon Dioxide clones rotate at a wider angle. What did you change in the code? |
Press the ‘Activity’ button to access Option A Activity: Task 2.
Press ‘Let’s Check!’ to access the correct responses for Option A Task 2.
Questions |
Your responses |
---|---|
Describe the movement of each Carbon Dioxide clone before they are removed from the stage. |
The Carbon Dioxide clones begin at a random position, then rotated at a random angle between -30 to 30 degrees so that they do not move across the stage in a straight line. They are then moved forward by five steps, and this is repeated 15 times, so it appears to do so gradually. |
Alter the code to move the Carbon Dioxide clones more quickly across the stage. What did you change in the code? |
To make the Carbon Dioxide clones move faster, alter the move five steps inside of the repeat block to a higher value. |
Alter the code to make some of the Carbon Dioxide clones rotate at a wider angle. What did you change in the code? |
To make the Carbon Dioxide clones rotate at a wider angle, alter the pick random values inside of the turn block to larger integers. For example, -60 to 60. |
If you would like to create the previously explore Scratch code, continue with Option B to create the entire Scratch application by following the guided steps.
Option B
For this option, we will remix and alter the code in Scratch.
Access the following completed Scratch code: Scratch(Opens in a new window)
Let’s begin the code for this project in Scratch on your own device.
Step 1: Tree sprite
We’ll get started with the code for the “Trees” sprite. This will need five scripts to get it set up for what we want it to do.

Press the following tabs to access information about the five scripts in the code.
Build the following script:
The first script for the Trees sprite with the following blocks: when Green Flag clicked, set ppm of CO2 to 400, go to x:0 y:0, show, and a Control block for "forever" with the blocks for next costume, and wait 0.25 seconds.
This code starts with 400 ppm of CO2 every time (using the set (PPM OF CO2) TO (400) block) and puts the tree in the middle of the frame (using the GO TO X:0, Y:0 block) for the player to begin planting tree clones. The FOREVER, NEXT COSTUME, WAIT (0.25) SECONDS loop set of blocks ensures the initial sprite is animated in its movements. There are two different costumes in the “Costumes” tab at the top left of the editor.
Build the following script:
The second script for the Trees sprite with the following blocks: when this sprite clicked, create clone of myself, change ppm of CO2 by -5, broadcast fix carbon, and a Control block for "forever" with the blocks for wait until ppm of CO2 < 350, switch backdrop to Well done, hide, and stop all.
This script sets up the cloning element for the trees, as well as decreases the ppm of CO2 by five for every new tree that is planted. The BROADCAST (FIX CARBON) block will send a message to the “Carbon Dioxide” sprite to delete clones of itself whenever a “Trees” sprite is pressed (a tree is planted). The forever loop set of blocks in this chain ensures that the game is ended when ppm of CO2 has reached the goal of 350. Only then will the “Well done” backdrop appear and all running code will stop.
Build the following script:
The third script for the Trees sprite with the following blocks: when I start as a clone, and a Control block for "forever" with the blocks for next costume, and wait 0.25 seconds.
Build the following script:
The fourth script for the Trees sprite with the following blocks: when Green Flag clicked, and a Control block for "forever" with the blocks for wait until ppm of CO2 = 350, and hide.
Build the following script:
The fifth script for the Trees sprite with the following blocks: when I start as a clone, go to random position, and a Control block for "forever" with the blocks for wait until touching mouse-pointer? and mouse down?, repeat until not mouse down?, go to mouse-pointer, and play hooray sound until done.
This script makes clones appear in a random position. The forever loop set of blocks might seem a little complicated, but all it is ensuring is that the “Trees” clones can be pressed on (mouse down?) and dragged to be planted. When the mouse press button is released, a “hooray” sound will confirm that a tree was successfully planted.
Step 2: Carbon dioxide sprite
Great job! Now, let’s work on the code for the “Carbon Dioxide” sprite. This will need three scripts to get it set up for what we want it to do:

Press the following tabs to access information about the three scripts in the program.
Build the following script:
The first script for the Carbon Dioxide sprite with the following blocks: when Green Flag clicked, go to x: -188 y:117, a Control block for "repeat until ppm of CO2 < 350 " with the block for create clone of myself, and a Control block for "forever " with the blocks wait until ppm of CO2 < 350, and hide.
This script starts in the sky with the GO TO X: (-188) Y: (117) block. The REPEAT UNTIL… and CREATE CLONE OF (MYSELF) loop set of blocks makes the condition that cloning of the sprite will only keep happening until the ppm of CO2 is below 350. The FOREVER LOOP set of blocks ensures that the sprite is hidden from view when the game is over.
Build the following script:
The second script for the Carbon Dioxide sprite with the following blocks: when I start as a clone, set size to 100%, show, go to random position, turn right pick random -30 to 30 degrees, a Control block for "repeat 15" with the block for move 5 steps, and delete this clone. How are the carbon dioxide clones animated in the code?
This script sets up the movement/animation of the “Carbon dioxide” clones. It is meant to be random in terms of direction and location to mimic the movements of real gas particles (with the GO TO…, TURN…DEGREES, and REPEAT… + MOVE… blocks). After this random movement, the clone is deleted.
Build the following script:
The third script for the Carbon Dioxide sprite with the following blocks: when I receive fix carbon, delete this clone.
In this script, when this sprite receives “fix carbon” from the “Trees” sprite (because a new tree has been planted), clones are deleted to show the reduction in carbon dioxide in the atmosphere each time a new tree is planted.
Step 3: Backdrops
Finally, we need to do a bit of code for the backdrops, as well. This will switch it back from the “Well Done” to the “Blue Sky” backdrop every time the green flag is pressed to start the game/program over again:

The script for the backdrop with the following blocks: when Green Flag clicked, switch backdrop to Blue Sky.
Consolidation
Test it out!

Before we share this game with friends, relatives, or peers, refer to the following checklist:
Did you…?
Learning check!
For each sentence, select the missing word from the drop-down menu.
Pause and Reflect
Pause and reflect
Choose three or more of the following questions to reflect on and respond to.
- What did you enjoy about coding or remixing existing code? What is one thing you want to continue to explore? What might you do differently next time?
- How did coding a simulation help you to understand actions that humans can take to reduce greenhouse emissions?
- What are some common sources of greenhouse gases?
- How is planting trees and reducing greenhouse gases connected to fighting climate change? Create a visual (illustration, art piece, diagram), written or oral description, etc. that displays this connection.
- How does planting trees promote sustainability and help us achieve the United Nations goal of sustainability in our cities and communities?
Record your thoughts and responses in a notebook or another method of your choice.
Press ‘Let’s Check!’ to access a detail about the United Nations goal.
To promote sustainability, land restoration is the answer! Planting trees or reforestation can actually have impact on all 17 of the United Nations’ Sustainable Development Goals!
Reflection
As you read the following descriptions, select the one that best describes your current understanding of the learning in this activity. Press the corresponding button once you have made your choice.
I feel…
Now, expand on your ideas by recording your thoughts using a voice recorder, speech-to-text, or writing tool.
When you review your notes on this learning activity later, reflect on whether you would select a different description based on your further review of the material in this learning activity.