Lesson 3: Decision Trees
Estimated time: 15-20 minutes | Screen-Free Activity
What You Will Learn
By the end of this lesson, your child will be able to:
- Explain what a decision tree is and how to read one
- Trace a path through a decision tree by answering yes/no questions
- Draw their own decision tree on paper
What is a Decision Tree?
In the last lesson, you sorted objects by asking yes/no questions. A decision tree is a picture that shows those questions as a branching path. Each question is a fork in the road: one path goes to "yes" and the other goes to "no."
Decision Tree -- A diagram that looks like an upside-down tree. It starts with one question at the top and branches out. Each branch leads to another question or to a final answer. You follow the branches by answering yes or no at each step.
Decision trees are like flowcharts with choices. In Module 3, your flowcharts went straight from start to finish. Now, decision trees have branches where the path splits based on a question. This is where it gets really interesting!
Example: Should I Go Outside?
Let us trace through a simple decision tree together. Start at the top and answer each question.
Trace It Together
Look at the tree with your child. Ask: "What if it IS raining and you DO have a raincoat? Where do you end up?" (Answer: "Go outside with raincoat!") Then try: "What if it is NOT raining and it is NOT very hot?" (Answer: "Go outside and play!") Trace each path with your finger.
Example: What Animal Am I?
Decision trees are great for guessing games too. Here is a simple tree that identifies animals:
This tree uses just two questions to sort animals into four groups. If the animal has legs and can fly, it is probably a bird. If it has legs but cannot fly, it might be a dog or cat. If it has no legs and lives in water, it is a fish. If it has no legs and does not live in water, it is a snake.
Try It: Trace the Path
Think of a goldfish. Start at the top of the tree.
- Does it have legs? NO -- go right.
- Does it live in water? YES -- go left.
- Result: Fish! Correct!
Now try an eagle, then a snake. Does the tree get the right answer each time?
Choose Your Own Adventure
Have you ever read a "Choose Your Own Adventure" book? Those books are decision trees! At the end of each page, you make a choice, and that choice sends you to a different part of the story.
A Mini Adventure
You are exploring a cave. You come to a fork in the path.
Do you go left or right?
- LEFT: You find a room full of glowing crystals! Do you pick one up?
- YES: The crystal lights your way deeper into the cave. You find a treasure chest!
- NO: You admire the crystals and head back to the entrance. A beautiful sunset greets you.
- RIGHT: You hear a sound. Do you keep going?
- YES: You discover a friendly bat family! They show you a secret exit.
- NO: You decide to go back. Better safe than sorry! You enjoy a quiet walk home.
This little story has 4 possible endings, all decided by yes/no choices. That is a decision tree!
Activity: Draw a "What Should I Wear?" Decision Tree
Screen-Free Activity (10 minutes)
What you need: A big piece of paper and colored pencils or markers.
What to do:
- At the top of your paper, write the question: "Is it cold outside?"
- Draw two lines going down from it. Label one "YES" and one "NO."
- Under YES, write another question: "Is it raining?"
- Under NO, write another question: "Is it sunny?"
- Draw two more branches from each of those questions.
- At the bottom of each branch, draw or write what to wear!
- Cold + Raining = Warm coat and rain boots
- Cold + Not Raining = Warm coat and regular shoes
- Not Cold + Sunny = T-shirt and sunglasses
- Not Cold + Not Sunny = Light jacket
Make it your own: Add more questions! What about wind? What about snow? The more questions, the bigger the tree. Draw pictures of the outfits at the bottom of each branch.
Activity: Create Your Own Adventure
Bonus Activity: Write a Mini Adventure
What you need: Paper and pencil.
What to do:
- Start with a situation: "You are a space explorer and you land on a new planet."
- Give the reader a choice: "Do you explore the forest or the ocean?"
- For each choice, write what happens next and give another choice.
- Keep branching until you have at least 4 different endings.
- Read it aloud and let your parent (or a sibling) choose the path!
Your child can write about anything: a princess rescuing a dragon, a detective solving a mystery, a chef in a magical kitchen. The topic does not matter -- the decision tree structure is the learning.
Parent Tip
This is a wonderful activity that blends creative writing with logical thinking. If your child loves stories, they will love building decision trees this way. Do not worry about spelling or neatness. Focus on the branching structure: every choice leads to different paths.
Check Your Understanding
1. What is a decision tree?
2. How is a decision tree different from a flowchart?
3. In the "Should I Go Outside?" tree, what happens if it is not raining and it is very hot?
Key Takeaways
- A decision tree is a diagram with branching paths based on yes/no questions
- You start at the top and follow branches by answering each question
- Decision trees are like flowcharts with choices -- the path splits instead of going straight
- "Choose Your Own Adventure" stories are decision trees in disguise
- Decision trees can help you sort things, make choices, or tell interactive stories
- Computers use decision trees constantly to make smart decisions
Ready for More?
Next Lesson
In Lesson 4, you will use if/then blocks in Scratch to make sprites respond to key presses and make interactive stories!
Start Lesson 4