Skip to content
PlayOwl

Coding · Grade 6

Input, Output and Variables

Learners see assignment as an instruction (work out the right side, then store), read user input with input() and convert it with int() and float(), format output with f-strings and choose valid, meaningful names. They finish by tracing complete programs, including the classic swap bug and its fix.

  • 4 lessons
  • About 80 minutes
  • Check what you learned: 8 questions
  • Ways to answer: fill in the blanks, choose an answer, put code in order, trace code, highlight a text and type a number
Try it now (no account) One of the five free starter courses Open in PlayOwl

What learners will discover

  • Explain assignment: the right-hand side is worked out first, then stored, replacing the variable's old value.
  • Read user input with input() and convert it with int() or float() before doing maths.
  • Produce clear output with f-strings and choose valid, meaningful variable names.
  • Trace programs that read input and update variables, including swapping two values with a temporary variable.

Lessons

  1. Variables and assignment 6 steps3 practiceabout 18 min
  2. Input and type conversion 6 steps4 practiceabout 20 min
  3. Clear output and good names 6 steps4 practiceabout 18 min
  4. Tracing whole programs 6 steps3 practiceabout 19 min
  5. Check what you learned 8 questions at the end

Keep exploring

Games to practice with

More 6th grade coding

Guide for grown-ups