Skip to the content
Peabody TeachFor teachers and grown-ups

Instructions a Machine Can Follow: teacher key

How Coding Works, grade 9 edition, written for 9th grade. Writing code means giving a computer precise, ordered instructions. Algorithms, binary, early languages, the building blocks of programs, Python, Scratch and bug-fixing are all part of it.

Read the book. Print this page for the key.

Questions and answers

  1. What does a compiler do?
    • It translates a program into machine code the computer can run (answer)
    • It finds typing mistakes by itself
    • It makes a computer think for itself
  2. Who is named as the person who coined the word compiler?
    • John Backus
    • Grace Hopper (answer)
    • Guido van Rossum
  3. What does a loop do?
    • It makes a computer repeat a set of instructions (answer)
    • It turns code into binary
    • It holds a value that never changes
  4. A program gives the wrong answer because its instructions are in the wrong order. Which kind of bug is that?
    • A syntax error
    • A logic error (answer)
    • A comment
  5. Why can a variable keep track of a score?
    • Its value can change (answer)
    • It can only be true or false
    • It is written in machine code
  6. In the passage, what does the word syntax mean?
    • The rules for how code must be written (answer)
    • A kind of computer hardware
    • A note the computer does not run

Words

  • algorithm: step-by-step procedure
  • compiler: code translator
  • variable: value container
  • debugging: fixing bugs
  • syntax: writing rules