Eighth graders learn that the best programmers write for people as well as computers, using comments to explain their code so others, and their future selves, can understand it, then check what they know.
Students will be able to…
You open code you wrote months ago and cannot remember how it works, and a short note in the code could have saved you. What are comments, and why do programmers write them?
Project this and answer each question about comments and how they make code easier to understand — read the explanation after each one.
Tap any phase to open the teacher moves and student actions.
You open code you wrote months ago and cannot remember how it works. A short note left in the code could have saved you. What are comments, and why do programmers write them?
Students answer questions about comments.
Students add a helpful comment.
Students comment a short program.
Students reflect on comments.
Aligned to the CSTA K-12 Computer Science Standards and the ISTE Standards for Students.
Document a program with comments to make it easier to follow.
Systematically improve and maintain programs for others to use.
Describe how documentation helps people work together on code.
Computational Thinker: create and document clear, reusable solutions.
Preview the three formative checks. Tap “Sample answer” to see what mastery looks like — hide them before you print for students.
Have students take a short program, add a comment at the top, and explain the tricky parts, so writing for people becomes part of coding. A printable code-comments worksheet is in the Computer Science library.
Tap a card to flip it, then rate whether you knew it. Built from this lesson’s vocabulary.
A quick self-check with instant feedback, drawn from this lesson’s key terms.
A print-and-go review sheet with a built-in answer key. Tap “Show answer key” to reveal answers, or print the clean version for students.