Empathize with students who struggled to get their code working, these students may not be ready to think about how to advance the design of their program; suggesting they refactor their code immediately after it finally runs can be discouraging.

  • Often times students are incredibly relieved finally have their code successfully running.
    • If you suggest refactoring and advancing the design of code as soon as it’s working, some students may get upset, be uninterested, or become defensive.
  • Teaching good design is difficult.
  • Search for ways to demonstrate good examples of refactored code that encourages the student rather than discourages them.

More about this tip

External Source

Interview with Richard Weiss.