Code Championship Logo

Curriculum

Disclaimer

This curriculum is a work in process. We're a very small company and only a handful of very passionate instructors are using this curriculum, so it is not as well supported as we would like it to be. If you have any questions or feedback, please reach out to me directly at [email protected]

- Luke Schlangen, Co-Founder of Code Championship

Timeline

Four 3-hour days for a total of 12 hours of curriculum

Student Objectives

  • To be excited about writing code
  • To be able to create a bot using Scratch
  • To be able to compete head-to-head against other students using code

Terminology

  • Students → "Coders" or "Players"
  • Instructors → "Coaches" or "Referees"
  • Base projects to start from → "Games" or "Challenges"
  • Projects built by students → "Bots"

Daily Structure

  1. Name game
  2. Introduce the challenge for the day
  3. One hour to build/test a bot
  4. Break for stretching/snack
  5. Introduce a new strategy/computer science principle
  6. One hour to build/test a bot
  7. Break for stretching/snack
  8. Pool Play
  9. Tournament Play
  10. Wind Down/Sportsmanship Time
  11. Show Advanced Code Examples

Important Links

Tournament Page

Preparation Checklist

  • Power up computers immediately upon arrival. Some will have a long startup process (Leave a couple extra computers logged on if another crashes during the class).
  • Find/Read Emergency Procedures for the classroom or ask the community ed director about emergency procedures
  • Ask what the expectations of instructors are for their host (they are all different).
  • Ask for the Check-In Procedure: Do you pick up the students, or do they get dropped off in the classroom?
  • Ask the community ed director if and where they can go outside for break
  • Find where the nearest bathrooms and drinking fountains are
  • Verify the pick up procedure at the end of the day
  • Do you wait for the kids or do the school officials?
  • Do you bring the kids somewhere or keep them in the classroom?
  • When the parents drop the children off, introduce yourself and thank them for being in the class. Explain the pickup process and encourage them to bring a snack and earbuds the next day (if the school where you are teaching does not provide them.)
  • Take a bathroom break before class starts

Classroom Procedures

Rules we would like them to guess themselves (if not, lead them that direction until they can guess)

  • Be respectful and encouraging - help each other out
  • Use your indoor voices, this is a computer lab
  • If you have a question, raise your hand
  • Don’t touch others computers (we want them to learn on their own!)
  • Stay on the websites we are working on
  • At the end of class, clean your space
  • Remember you are using school property, so you are responsible for the property you use for the week
  • Explain the class structure: Break halfway (Snacks, Bathroom, Outside?) and Hands-on Activities

Create a penalty box where coders will go if they violate a rule. Rule violations (fouls) will result in 2-minute penalties. Everything should be framed in the context of the game. The referee/coach will have the discretion to assign penalty times for flagrant fouls (fouls beyond those described in the rules).

Hallway Procedures

Important! Be sure to set expectations BEFORE you leave the room.

  • We use indoor voices in the hall
  • We walk and keep our hands to ourselves
  • We walk together. No one runs ahead in front of the coach. The coach is the first one in the line.
  • We will take bathroom breaks

Lesson 1 - Introduction to Scratch

Link to Slides

Learning Objectives

  • To understand fully understand what is coding
  • To understand Scratch (and other coding languages) and what it provides
  • To understand Scratch “My Blocks” (directional movement)

Important Concepts/Vocabulary

  • Code: Instructions for a program
  • Coding: Is a list of instructions you give to a computer that it follows.
  • Coder: An individual who writes code
  • Scratch: Is a block-based visual programming language
  • Directionals: Movement in any direction (example: left, right, up and down)

Learning Activities/Games

Computer Instructions

  • Programmer Says (Like Simon Says)
  • Red Light, Green Light

Directionals

The Great Escape - Group Game

Set up an obstacle course with chairs or other objects in the room. A player starts at the other side of the room, while the others are giving the player directions (move right, move left, move forward, move back) to escape the obstacle course

Mr Roboto - Group Game

1 player are the hands/body (does all the motion), 1 player is the eyes (can only state what they see), and 1 player is the brain (process what they see, and tell the hands/body what to do).

Maze Runner

Materials: 64 sheets of paper, or masking tape, to make an 8x8 grid

Players have to walk on the paper and hope that they are going the right way, one at a time. If the player goes the wrong way, it will be mentioned, and the player will have to retrace their steps and start over, and have another person go. The goal of the game is for the whole team to make it out of the maze.

Code Championship Challenge

Rabbit Race


Lesson 2 - Loops Introduction

Link to Slides

Learning Objectives

  • To understand what loops can provide while coding
  • To understand the three different loops that Scratch has

Important Concepts/Vocabulary

  • Scratch: The coding language that Code Championship uses
  • Loop: A way to repeat code multiple time
  • Repeat # : This loop will repeat as many times based on the # the programmer gives it
  • Repeat Until: This loop will repeat until a certain condition is met
  • Forever: This loop will continue to repeat forever

Learning Activities/Games

  • Programmer Says 2.0 (similar to Simon Says but with loops)

Code Championship Challenge

Focus on using fewer blocks

Rabbit Race


Lesson 3 - Conditionals Introduction

Link to Slides

Learning Objectives

  • To understand “if” and “else” statements and what they are used for
  • To understand conditional operators

Important Concepts/Vocabulary

  • Conditional: Code that decides which code to run
  • Operators: Mathematical expressions/characters that represent some type of action
    • <
    • >
    • =
    • and
    • or
    • not

Learning Activities/Games

Write a "choose your own adventure" story

Materials: 16 note cards per coder

Write a number on each note card. On note card #1, write a question. Depending on how the reader answers, they should be sent to a new note card (like #2 or #3). Then the reader should see another question. Repeat!

If-Else Direction Game

One person is the coder who give if (and else) statements, and everyone are the computer who are interpreting the instructions and carrying them out.

Ex: If I touch my left elbow then take a step to the left (else take a step to the right), or if I touch my right elbow then take a step to the right.

Code Championship Challenge

Skyward Cannons


Lesson 4 - Sensing Introduction

Link to Slides

Learning Objectives

  • To understand sensing and what it’s used for
  • To incorporate sensing with conditionals

Important Concepts/Vocabulary

  • Sensing: Identifying an object or space relative to a given position
  • Distance to … (Distance to Target 2)
  • … of … (x position of Target 1)

Learning Activities/Games

Heads Up, Seven Up

Seven students stand in front of the class. The rest of the students put their heads on their desks. The seven then move about and each touches a student. Once touched, a student sticks his or her thumb up. Then the seven say “heads up seven up!” The students who were touched then get a chance to guess which of the seven touched each of them. If they guessed right, they get to change places and be one of the students in the front.

Code Championship Challenge

At this point, a coder should be able to compete in any challenge.

Battle Cannons and Jewel Drill


Lesson 5 - Debugging Introduction

Link to Slides

Learning Objectives

  • To understand debugging and what it’s used for
  • How to debug code

Important Concepts/Vocabulary

  • Debugging: The process of identifying and removing errors from code
  • Error: Is a bug in a program to cause it to operate incorrectly

Learning Activities/Games

The Power of Debugging

Activity Slides

Code Championship Challenge

At this point, a coder should be able to compete in any challenge.


Lesson 6 - Variables and Functions Introduction

Link to Slides

Learning Objectives

  • To understand what is a variable
  • To understand what is a function

Important Concepts/Vocabulary

  • Variable: Is a placeholder for a piece of information that can change
  • Function: A reusable bit of code

Learning Activities/Games

Variables:

Mad Libs (find some online)

Assigning something to the given word

  • Ex: Noun 1 = code
  • Ex: Verb 2 = running

Functions:

What's my function
Activity Slides

Break the coders into groups and give them a job description. The coders will then have to come up with a way for that worker to complete their tasks.

Job Descriptions:

  • Sandwich Decorator
  • Smoothie/Shake Barista
  • Car Cleaner/Washer
  • Salad Decorator
  • Packer for a Camping Trip

Code Championship Challenge

At this point, a coder should be able to compete in any challenge. Use functions to reduce the block count for their bots.

Scratch Function Block Review

My Blocks

  • Move X: moves bot in the direction indicated.
  • Control

    • Wait X seconds: The program will wait that amount.
    • Repeat X: Will repeat any code inside X amount of times.
    • Forever: Repeats code inside forever.
    • If X then: If X happens then the code inside will run.
    • If X then, else: If X happens then code inside will run, otherwise else will run
    • Wait until X: Program will stop until X happens.
    • Repeat until X: Code will repeat until X happens.

    Motion

    • x position: returns the value of the horizontal position of the bot
    • y position: returns the value of the vertical position of the bot

    Sensing

    • touching X:determines whether or not the bot is touching a certain object X
    • distance to X:returns a value that is the numerical distance of the bot from a certain object X

    Operators

    • Arithmetic Operators
      • X + Y: performs addition between two numbers X and Y, and returns the sum between the two
      • X - Y: performs subtraction between two numbers X and Y, and returns the difference between the two
      • X * Y: performs multiplication between two numbers X and Y, and returns the product between the two
      • X / Y: performs division between two numbers X and Y, and returns the quotient between the two
    • pick random X to Y: Returns a random number between a number X and a number Y
    • Comparison Operators
      • X > Y: determines whether or not a value X is greater than a value Y
      • X < Y: determines whether or not a value X is less than a value Y
      • X = Y: determines whether or not a value X is equal to a value Y
    • Logical Operators
      • X and Y: determines whether or not two conditions, X and Y, have both occurred
      • X or Y: determines whether or not one, or both, of two conditions, X or Y, has occurred
      • not X: reverses the logical determination of the condition X